Added in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

# TelephonyCallback.DataActivationStateListener

*** ** * ** ***

` public static interface TelephonyCallback.DataActivationStateListener `   
` `

|---|
| android.telephony.TelephonyCallback.DataActivationStateListener |

<br />

*** ** * ** ***

Interface for SIM data activation state listener.

## Summary

| ### Public methods ||
|---|---|
| ` abstract void` | ` https://developer.android.com/reference/android/telephony/TelephonyCallback.DataActivationStateListener#onDataActivationStateChanged(int)(int state) ` Callback invoked when the SIM data activation state has changed on the registered subscription. |

## Public methods

### onDataActivationStateChanged

Added in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract void onDataActivationStateChanged (int state)
```

Callback invoked when the SIM data activation state has changed on the registered subscription. Note, the registration subscription ID comes from `https://developer.android.com/reference/android/telephony/TelephonyManager` object which registers TelephonyCallback by `https://developer.android.com/reference/android/telephony/TelephonyManager#registerTelephonyCallback(java.util.concurrent.Executor,%20android.telephony.TelephonyCallback)`. If this TelephonyManager object was created with `https://developer.android.com/reference/android/telephony/TelephonyManager#createForSubscriptionId(int)`, then the callback applies to the subscription ID. Otherwise, this callback applies to `https://developer.android.com/reference/android/telephony/SubscriptionManager#getDefaultSubscriptionId()`.

<br />

| Parameters ||
|---|---|
| `state` | `int`: is the current SIM data activation state. Value is one of the following: |