共用方式為


NfcAdapter.SetOnNdefPushCompleteCallback Method

Definition

Set a callback on successful Android Beam (TM).

[Android.Runtime.Register("setOnNdefPushCompleteCallback", "(Landroid/nfc/NfcAdapter$OnNdefPushCompleteCallback;Landroid/app/Activity;[Landroid/app/Activity;)V", "")]
public void SetOnNdefPushCompleteCallback (Android.Nfc.NfcAdapter.IOnNdefPushCompleteCallback? callback, Android.App.Activity? activity, params Android.App.Activity[]? activities);
[<Android.Runtime.Register("setOnNdefPushCompleteCallback", "(Landroid/nfc/NfcAdapter$OnNdefPushCompleteCallback;Landroid/app/Activity;[Landroid/app/Activity;)V", "")>]
member this.SetOnNdefPushCompleteCallback : Android.Nfc.NfcAdapter.IOnNdefPushCompleteCallback * Android.App.Activity * Android.App.Activity[] -> unit

Parameters

callback
NfcAdapter.IOnNdefPushCompleteCallback

callback, or null to disable

activity
Activity

activity for which the NDEF message will be pushed

activities
Activity[]

optional additional activities, however we strongly recommend to only register one at a time, and to do so in that activity's Activity#onCreate

Attributes

Remarks

Java documentation for android.nfc.NfcAdapter.setOnNdefPushCompleteCallback(android.nfc.OnNdefPushCompleteCallback, android.app.Activity, android.app.Activity).

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