DataConnectionStateListener
interface DataConnectionStateListener
android.telephony.TelephonyCallback.DataConnectionStateListener |
Interface for data connection state listener.
Summary
Public methods | |
---|---|
abstract Unit |
onDataConnectionStateChanged(state: Int, networkType: Int) Callback invoked when connection state changes on the registered subscription. |
Public methods
onDataConnectionStateChanged
abstract fun onDataConnectionStateChanged(
state: Int,
networkType: Int
): Unit
Callback invoked when connection state changes on the registered subscription. Note, the registration subscription ID comes from TelephonyManager
object which registers TelephonyCallback by TelephonyManager.registerTelephonyCallback(Executor, TelephonyCallback)
. If this TelephonyManager object was created with TelephonyManager.createForSubscriptionId(int)
, then the callback applies to the subscription ID. Otherwise, this callback applies to SubscriptionManager.getDefaultSubscriptionId()
.