共用方式為


EuiccManager.IsSimPortAvailable(Int32) Method

Definition

Returns whether the passing portIndex is available.

[Android.Runtime.Register("isSimPortAvailable", "(I)Z", "GetIsSimPortAvailable_IHandler", ApiSince=33)]
public virtual bool IsSimPortAvailable (int portIndex);
[<Android.Runtime.Register("isSimPortAvailable", "(I)Z", "GetIsSimPortAvailable_IHandler", ApiSince=33)>]
abstract member IsSimPortAvailable : int -> bool
override this.IsSimPortAvailable : int -> bool

Parameters

portIndex
Int32

is an enumeration of the ports available on the UICC.

Returns

true if port is available

Attributes

Remarks

Returns whether the passing portIndex is available. A port is available if it is active without enabled profile on it or calling app has carrier privilege over the profile installed on the selected port.

From Android U, a port is available if it is active without an enabled profile on it or calling app can activate a new profile on the selected port without any user interaction.

Always returns false if the cardId is a physical card.

Java documentation for android.telephony.euicc.EuiccManager.isSimPortAvailable(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