Package org.robolectric.shadows
Class ShadowImsMmTelManager
java.lang.Object
org.robolectric.shadows.ShadowImsMmTelManager
@Implements(value=android.telephony.ims.ImsMmTelManager.class,
minSdk=29,
looseSignatures=true,
isInAndroidSdk=false)
public class ShadowImsMmTelManager
extends Object
Supports IMS by default. IMS unregistered by default.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
protected static ImsMmTelManager
createForSubscriptionId
(int subId) Returns only one instance per subscription id.void
getRegistrationState
(Executor executor, Consumer<Integer> stateCallback) void
getRegistrationTransportType
(Executor executor, Consumer<Integer> transportTypeCallback) int
Get subscription idprotected boolean
isAvailable
(int capability, int imsRegTech) protected void
protected void
protected void
void
setImsAvailableOnDevice
(boolean imsAvailableOnDevice) Sets whether IMS is available on the device.void
setImsRegistered
(int imsRegistrationTech) TriggersRegistrationCallback#onRegistered(int)
for all registeredRegistrationCallback
callbacks.void
void
setImsRegistering
(int imsRegistrationTech) TriggersRegistrationCallback#onRegistering(int)
for all registeredRegistrationCallback
callbacks.void
void
setImsUnregistered
(ImsReasonInfo imsReasonInfo) TriggersRegistrationCallback#onUnregistered(ImsReasonInfo)
for all registeredRegistrationCallback
callbacks.void
setMmTelCapabilitiesAvailable
(MmTelFeature.MmTelCapabilities capabilities) Sets the availableMmTelFeature.MmTelCapabilities
.void
setOnTechnologyChangeFailed
(int imsRadioTech, ImsReasonInfo imsReasonInfo) TriggersRegistrationCallback#onTechnologyChangeFailed(int, ImsReasonInfo)
for all registeredRegistrationCallback
callbacks.static void
setRegistrationState
(int subId, int registrationState) static void
setRegistrationTransportType
(int subId, int registrationTransportType) protected void
protected void
protected void
-
Constructor Details
-
ShadowImsMmTelManager
public ShadowImsMmTelManager()
-
-
Method Details
-
setImsAvailableOnDevice
public void setImsAvailableOnDevice(boolean imsAvailableOnDevice) Sets whether IMS is available on the device. Setting this to false will causeImsException
to be thrown whenever methods requiring IMS support are invoked includingregisterImsRegistrationCallback(Executor, RegistrationCallback)
andregisterMmTelCapabilityCallback(Executor, CapabilityCallback)
. -
registerImsRegistrationCallback
@Implementation protected void registerImsRegistrationCallback(@NonNull Executor executor, @NonNull ImsMmTelManager.RegistrationCallback c) throws ImsException - Throws:
ImsException
-
registerImsRegistrationCallback
@Implementation(minSdk=30) protected void registerImsRegistrationCallback(@NonNull Executor executor, @NonNull RegistrationManager.RegistrationCallback c) throws ImsException - Throws:
ImsException
-
unregisterImsRegistrationCallback
@Implementation protected void unregisterImsRegistrationCallback(@NonNull ImsMmTelManager.RegistrationCallback c) -
unregisterImsRegistrationCallback
@Implementation(minSdk=30) protected void unregisterImsRegistrationCallback(@NonNull RegistrationManager.RegistrationCallback c) -
setImsRegistering
public void setImsRegistering(int imsRegistrationTech) TriggersRegistrationCallback#onRegistering(int)
for all registeredRegistrationCallback
callbacks. -
setImsRegistering
-
setImsRegistered
public void setImsRegistered(int imsRegistrationTech) TriggersRegistrationCallback#onRegistered(int)
for all registeredRegistrationCallback
callbacks. -
setImsRegistered
-
setImsUnregistered
TriggersRegistrationCallback#onUnregistered(ImsReasonInfo)
for all registeredRegistrationCallback
callbacks. -
setOnTechnologyChangeFailed
TriggersRegistrationCallback#onTechnologyChangeFailed(int, ImsReasonInfo)
for all registeredRegistrationCallback
callbacks. -
setRegistrationState
public static void setRegistrationState(int subId, int registrationState) -
getRegistrationStateCallback
-
getRegistrationState
@HiddenApi @Implementation(minSdk=30) public void getRegistrationState(Executor executor, Consumer<Integer> stateCallback) -
setRegistrationTransportType
public static void setRegistrationTransportType(int subId, int registrationTransportType) -
getRegistrationTransportTypeCallback
-
getRegistrationTransportType
@Implementation(minSdk=30) public void getRegistrationTransportType(Executor executor, Consumer<Integer> transportTypeCallback) -
registerMmTelCapabilityCallback
@Implementation protected void registerMmTelCapabilityCallback(@NonNull Executor executor, @NonNull ImsMmTelManager.CapabilityCallback c) throws ImsException - Throws:
ImsException
-
unregisterMmTelCapabilityCallback
@Implementation protected void unregisterMmTelCapabilityCallback(@NonNull ImsMmTelManager.CapabilityCallback c) -
isAvailable
-
setMmTelCapabilitiesAvailable
Sets the availableMmTelFeature.MmTelCapabilities
. Only invokesImsMmTelManager.CapabilityCallback.onCapabilitiesStatusChanged(MmTelCapabilities)
if IMS has been registered usingsetImsUnregistered(ImsReasonInfo)
. -
getSubscriptionId
public int getSubscriptionId()Get subscription id -
createForSubscriptionId
Returns only one instance per subscription id. -
clearExistingInstancesAndStates
-