語言

NfcA.Timeout 屬性

定義

以毫秒計時獲得當前 #transceive 超時。 -或者- 將暫停設 #transceive 在毫秒內。

public int Timeout { [Android.Runtime.Register("getTimeout", "()I", "")] get; [Android.Runtime.Register("setTimeout", "(I)V", "")] set; }
[<get: Android.Runtime.Register("getTimeout", "()I", "")>]
[<set: Android.Runtime.Register("setTimeout", "(I)V", "")>]
member this.Timeout : int with get, set

屬性值

以毫秒計的超時值

屬性

備註

財產取得者文件:

以毫秒計時獲得當前 #transceive 超時。

需要 android.Manifest.permission#NFC 權限。

Java 文件 android.nfc.tech.NfcA.getTimeout()。

屬性設定文件:

以毫秒計時。#transceive

超時只適用於 #transceive 此物件,且在呼叫時 #close 會重置為預設值。

在執行需要長時間處理標籤的交易(如金鑰產生)時,設定較長的逾時可能很有用。

需要 android.Manifest.permission#NFC 權限。

Java 文件 android.nfc.tech.NfcA.setTimeout(int)。

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於