Dela via


CardEmulation.CategoryAllowsForegroundPreference(String) Method

Definition

Returns whether the user has allowed AIDs registered in the specified category to be handled by a service that is preferred by the foreground application, instead of by a pre-configured default.

[Android.Runtime.Register("categoryAllowsForegroundPreference", "(Ljava/lang/String;)Z", "")]
public bool CategoryAllowsForegroundPreference (string? category);
[<Android.Runtime.Register("categoryAllowsForegroundPreference", "(Ljava/lang/String;)Z", "")>]
member this.CategoryAllowsForegroundPreference : string -> bool

Parameters

category
String

The category, e.g. #CATEGORY_PAYMENT

Returns

whether AIDs in the category can be handled by a service specified by the foreground app.

Attributes

Remarks

Returns whether the user has allowed AIDs registered in the specified category to be handled by a service that is preferred by the foreground application, instead of by a pre-configured default.

Foreground applications can set such preferences using the #setPreferredService(Activity, ComponentName) method.

Java documentation for android.nfc.cardemulation.CardEmulation.categoryAllowsForegroundPreference(java.lang.String).

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