# Print output for @column tags ?> ImsMmTelManager - Android SDK | Android Developers

Most visited

Recently visited

ImsMmTelManager

public class ImsMmTelManager
extends Object implements RegistrationManager

java.lang.Object
   ↳ android.telephony.ims.ImsMmTelManager


A manager for the MmTel (Multimedia Telephony) feature of an IMS network, given an associated subscription. Allows a user to query the IMS MmTel feature information for a subscription, register for registration and MmTel capability status callbacks, as well as query/modify user settings for the associated subscription. Use ImsManager.getImsMmTelManager(int) to get an instance of this manager.

Summary

Nested classes

class ImsMmTelManager.CapabilityCallback

Receives IMS capability status updates from the ImsService. 

Constants

int WIFI_MODE_CELLULAR_PREFERRED

Prefer registering for IMS over LTE if LTE signal quality is high enough.

int WIFI_MODE_WIFI_ONLY

Register for IMS over IWLAN if WiFi signal quality is high enough.

int WIFI_MODE_WIFI_PREFERRED

Prefer registering for IMS over IWLAN if possible if WiFi signal quality is high enough.

Inherited constants

Public methods

void getRegistrationTransportType(Executor executor, Consumer<Integer> transportTypeCallback)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()).

int getVoWiFiModeSetting()

Returns the user's voice over WiFi Roaming mode setting associated with the device.

boolean isAdvancedCallingSettingEnabled()

Query the user’s setting for “Advanced Calling” or "Enhanced 4G LTE", which is used to enable MmTel IMS features, depending on the carrier configuration for the current subscription.

boolean isTtyOverVolteEnabled()


Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

boolean isVoWiFiRoamingSettingEnabled()

Returns the user's voice over WiFi roaming setting associated with the current subscription.

boolean isVoWiFiSettingEnabled()


Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

boolean isVtSettingEnabled()

The user's setting for whether or not they have enabled the "Video Calling" setting.

void registerImsRegistrationCallback(Executor executor, RegistrationManager.RegistrationCallback c)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()).

void registerMmTelCapabilityCallback(Executor executor, ImsMmTelManager.CapabilityCallback c)

Registers a CapabilityCallback with the system, which will provide MmTel service availability updates for the subscription specified in ImsManager#getImsMmTelManager(int).

void unregisterImsRegistrationCallback(RegistrationManager.RegistrationCallback c)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()).

void unregisterMmTelCapabilityCallback(ImsMmTelManager.CapabilityCallback c)

Removes an existing MmTel CapabilityCallback.

Inherited methods

Constants

WIFI_MODE_CELLULAR_PREFERRED

public static final int WIFI_MODE_CELLULAR_PREFERRED

Prefer registering for IMS over LTE if LTE signal quality is high enough.

Constant Value: 1 (0x00000001)

WIFI_MODE_WIFI_ONLY

public static final int WIFI_MODE_WIFI_ONLY

Register for IMS over IWLAN if WiFi signal quality is high enough. Do not hand over to LTE registration if signal quality degrades.

Constant Value: 0 (0x00000000)

WIFI_MODE_WIFI_PREFERRED

public static final int WIFI_MODE_WIFI_PREFERRED

Prefer registering for IMS over IWLAN if possible if WiFi signal quality is high enough.

Constant Value: 2 (0x00000002)

Public methods

getRegistrationTransportType

public void getRegistrationTransportType (Executor executor, 
                Consumer<Integer> transportTypeCallback)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()). Access by profile owners is deprecated and will be removed in a future release. Gets the Transport Type associated with the current IMS registration.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Parameters
executor Executor: This value cannot be null. Callback and listener events are dispatched through this Executor, providing an easy way to control which thread is used. To dispatch events through the main thread of your application, you can use Context.getMainExecutor(). To dispatch events through a shared thread pool, you can use AsyncTask#THREAD_POOL_EXECUTOR.

transportTypeCallback Consumer: This value cannot be null. Value is android.telephony.AccessNetworkConstants.TRANSPORT_TYPE_INVALID, AccessNetworkConstants.TRANSPORT_TYPE_WWAN, or AccessNetworkConstants.TRANSPORT_TYPE_WLAN

getVoWiFiModeSetting

public int getVoWiFiModeSetting ()

Returns the user's voice over WiFi Roaming mode setting associated with the device.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
int The Voice over WiFi Mode preference set by the user, which can be one of the following: - WIFI_MODE_WIFI_ONLY - WIFI_MODE_CELLULAR_PREFERRED - WIFI_MODE_WIFI_PREFERRED Value is WIFI_MODE_WIFI_ONLY, WIFI_MODE_CELLULAR_PREFERRED, or WIFI_MODE_WIFI_PREFERRED

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

isAdvancedCallingSettingEnabled

public boolean isAdvancedCallingSettingEnabled ()

Query the user’s setting for “Advanced Calling” or "Enhanced 4G LTE", which is used to enable MmTel IMS features, depending on the carrier configuration for the current subscription. If this setting is enabled, IMS voice and video telephony over IWLAN/LTE will be enabled as long as the carrier has provisioned these services for the specified subscription. Other IMS services (SMS/UT) are not affected by this user setting and depend on carrier requirements.

Note: If the carrier configuration for advanced calling is not editable or hidden, this method will always return the default value.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
boolean true if the user's setting for advanced calling is enabled, false otherwise.

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

See also:

isTtyOverVolteEnabled

public boolean isTtyOverVolteEnabled ()


Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
boolean true if TTY over VoLTE is supported

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

See also:

isVoWiFiRoamingSettingEnabled

public boolean isVoWiFiRoamingSettingEnabled ()

Returns the user's voice over WiFi roaming setting associated with the current subscription.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
boolean true if the user's setting for Voice over WiFi while roaming is enabled, false if disabled.

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

isVoWiFiSettingEnabled

public boolean isVoWiFiSettingEnabled ()


Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
boolean true if the user's setting for Voice over WiFi is enabled and false if it is not.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

isVtSettingEnabled

public boolean isVtSettingEnabled ()

The user's setting for whether or not they have enabled the "Video Calling" setting.

Note: If the carrier configuration for advanced calling is not editable or hidden, this method will always return the default value.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Returns
boolean true if the user’s “Video Calling” setting is currently enabled.

Throws
IllegalArgumentException if the subscription associated with this operation is not active (SIM is not inserted, ESIM inactive) or invalid.

registerImsRegistrationCallback

public void registerImsRegistrationCallback (Executor executor, 
                RegistrationManager.RegistrationCallback c)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()). Registers a RegistrationCallback with the system. Use
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Parameters
executor Executor: This value cannot be null. Callback and listener events are dispatched through this Executor, providing an easy way to control which thread is used. To dispatch events through the main thread of your application, you can use Context.getMainExecutor(). To dispatch events through a shared thread pool, you can use AsyncTask#THREAD_POOL_EXECUTOR.

c RegistrationManager.RegistrationCallback: This value cannot be null.

Throws
ImsException

registerMmTelCapabilityCallback

public void registerMmTelCapabilityCallback (Executor executor, 
                ImsMmTelManager.CapabilityCallback c)

Registers a CapabilityCallback with the system, which will provide MmTel service availability updates for the subscription specified in ImsManager#getImsMmTelManager(int). Use SubscriptionManager.OnSubscriptionsChangedListener to listen to subscription changed events and call unregisterMmTelCapabilityCallback(android.telephony.ims.ImsMmTelManager.CapabilityCallback) to clean up.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release. When the callback is registered, it will initiate the callback c to be called with the current capabilities.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Parameters
executor Executor: The executor the callback events should be run on. This value cannot be null. Callback and listener events are dispatched through this Executor, providing an easy way to control which thread is used. To dispatch events through the main thread of your application, you can use Context.getMainExecutor(). To dispatch events through a shared thread pool, you can use AsyncTask#THREAD_POOL_EXECUTOR.

c ImsMmTelManager.CapabilityCallback: The MmTel CapabilityCallback to be registered. This value cannot be null.

Throws
ImsException if the subscription associated with this callback is valid, but the ImsService associated with the subscription is not available. This can happen if the service crashed, for example. See ImsException#getCode() for a more detailed reason.

See also:

unregisterImsRegistrationCallback

public void unregisterImsRegistrationCallback (RegistrationManager.RegistrationCallback c)

Requires Permission: READ_PRECISE_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager.hasCarrierPrivileges()). Access by profile owners is deprecated and will be removed in a future release. Removes an existing RegistrationCallback. When the subscription associated with this callback is removed (SIM removed, ESIM swap, etc...), this callback will automatically be removed. If this method is called for an inactive subscription, it will result in a no-op.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Parameters
c RegistrationManager.RegistrationCallback: This value cannot be null.

unregisterMmTelCapabilityCallback

public void unregisterMmTelCapabilityCallback (ImsMmTelManager.CapabilityCallback c)

Removes an existing MmTel CapabilityCallback. When the subscription associated with this callback is removed (SIM removed, ESIM swap, etc...), this callback will automatically be removed. If this method is called for an inactive subscription, it will result in a no-op.

This API requires one of the following:

The profile owner is an app that owns a managed profile on the device; for more details see Work profiles. Access by profile owners is deprecated and will be removed in a future release.
Requires android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE or Manifest.permission.READ_PRECISE_PHONE_STATE

Parameters
c ImsMmTelManager.CapabilityCallback: The MmTel CapabilityCallback to be removed. This value cannot be null.

See also: