Share via


PhoneStateListener.OnActiveDataSubscriptionIdChanged(Int32) Method

Definition

Callback invoked when active data subId changes.

[Android.Runtime.Register("onActiveDataSubscriptionIdChanged", "(I)V", "GetOnActiveDataSubscriptionIdChanged_IHandler", ApiSince=29)]
[Android.Runtime.RequiresPermission("android.permission.READ_PHONE_STATE")]
public virtual void OnActiveDataSubscriptionIdChanged (int subId);
[<Android.Runtime.Register("onActiveDataSubscriptionIdChanged", "(I)V", "GetOnActiveDataSubscriptionIdChanged_IHandler", ApiSince=29)>]
[<Android.Runtime.RequiresPermission("android.permission.READ_PHONE_STATE")>]
abstract member OnActiveDataSubscriptionIdChanged : int -> unit
override this.OnActiveDataSubscriptionIdChanged : int -> unit

Parameters

subId
Int32

current subscription used to setup Cellular Internet data. For example, it could be the current active opportunistic subscription in use, or the subscription user selected as default data subscription in DSDS mode.

Attributes

Remarks

Callback invoked when active data subId changes. Note, this callback triggers regardless of registered subscription.

Requires the READ_PHONE_STATE permission.

This member is deprecated. Use TelephonyCallback.ActiveDataSubscriptionIdListener instead.

Java documentation for android.telephony.PhoneStateListener.onActiveDataSubscriptionIdChanged(int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to