語言

DiscoverySession.InitiateBootstrappingRequest 方法

定義

多載

名稱 Description
InitiateBootstrappingRequest(PeerHandle, AwarePairingBootstrappingMethods)

依據 Wi-Fi Aware規範第4版定義。

InitiateBootstrappingRequest(PeerHandle, AwarePairingBootstrappingMethods, Byte[])

依據 Wi-Fi Aware 規範 4.0 版第 7.6.4.1 節定義。

InitiateBootstrappingRequest(PeerHandle, AwarePairingBootstrappingMethods)

依據 Wi-Fi Aware規範第4版定義。

[Android.Runtime.Register("initiateBootstrappingRequest", "(Landroid/net/wifi/aware/PeerHandle;I)V", "GetInitiateBootstrappingRequest_Landroid_net_wifi_aware_PeerHandle_IHandler", ApiSince=34)]
public virtual void InitiateBootstrappingRequest(Android.Net.Wifi.Aware.PeerHandle peerHandle, Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods method);
[<Android.Runtime.Register("initiateBootstrappingRequest", "(Landroid/net/wifi/aware/PeerHandle;I)V", "GetInitiateBootstrappingRequest_Landroid_net_wifi_aware_PeerHandle_IHandler", ApiSince=34)>]
abstract member InitiateBootstrappingRequest : Android.Net.Wifi.Aware.PeerHandle * Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods -> unit
override this.InitiateBootstrappingRequest : Android.Net.Wifi.Aware.PeerHandle * Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods -> unit

參數

peerHandle
PeerHandle

配對請求的對端帳號。 必須是某個事件DiscoverySessionCallback#onServiceDiscovered(ServiceDiscoveryInfo)的結果DiscoverySessionCallback#onMessageReceived(PeerHandle, byte[])。

method
AwarePairingBootstrappingMethods

其中一個 AwarePairingBootstrappingMethods 值,應與以下所接收的方法之一相容 PairingConfigBootstrappingMethods

屬性

備註

發起一個 Wi-Fi Aware bootstrapping 設定請求,以建立與目標對等端的配對。 Aware 的自助請求應該在發現會話的情境下進行——也就是在收到發佈/訂閱 DiscoverySessionCallback#onServiceDiscovered(ServiceDiscoveryInfo) 事件之後。 對等端會檢查該方法是否可由 AwarePairingConfig.Builder#setBootstrappingMethods(int) Aware Bootstrapping 設定完成後,雙方都會收到 DiscoverySessionCallback#onBootstrappingSucceeded(PeerHandle, int)

Java 文件 android.net.wifi.aware.DiscoverySession.initiateBootstrappingRequest(android.net.wifi.aware.PeerHandle, int)。

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

適用於

InitiateBootstrappingRequest(PeerHandle, AwarePairingBootstrappingMethods, Byte[])

依據 Wi-Fi Aware 規範 4.0 版第 7.6.4.1 節定義。

[Android.Runtime.Register("initiateBootstrappingRequest", "(Landroid/net/wifi/aware/PeerHandle;I[B)V", "GetInitiateBootstrappingRequest_Landroid_net_wifi_aware_PeerHandle_IarrayBHandler", ApiSince=37)]
public virtual void InitiateBootstrappingRequest(Android.Net.Wifi.Aware.PeerHandle peerHandle, Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods method, byte[] message);
[<Android.Runtime.Register("initiateBootstrappingRequest", "(Landroid/net/wifi/aware/PeerHandle;I[B)V", "GetInitiateBootstrappingRequest_Landroid_net_wifi_aware_PeerHandle_IarrayBHandler", ApiSince=37)>]
abstract member InitiateBootstrappingRequest : Android.Net.Wifi.Aware.PeerHandle * Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods * byte[] -> unit
override this.InitiateBootstrappingRequest : Android.Net.Wifi.Aware.PeerHandle * Android.Net.Wifi.Aware.AwarePairingBootstrappingMethods * byte[] -> unit

參數

method
AwarePairingBootstrappingMethods

該 AwarePairingBootstrappingMethods 方法與對等端所支援的方法相容。 從這些BootstrappingMethods方法PairingConfig及其屬性取得。

message
Byte[]

一個非空位元組陣列,可在服務描述符擴充屬性(SDEA)中作為服務資訊傳送——更多細節請參閱 Wi-Fi Aware 規格 9.5.4.2。 建議用於 CreateTxtRecordTlvBuffer(IDictionary<String,String>) 建立 DNS-SD 格式的鍵值訊息。

屬性

備註

依據 Wi-Fi Aware 規範 4.0 版第 7.6.4.1 節定義。 在發現工作階段中為同儕啟動啟動請求。 對等端會檢查其 SetBootstrappingMethods(AwarePairingBootstrappingMethods)支援的方法,由 設定為 ,是否符合相容性。 當啟動成功時,雙方都會收到 OnBootstrappingSucceeded(PeerHandle, AwarePairingBootstrappingMethods, Byte[])。

Android 參考資料。android.net.wifi.aware.DiscoverySession.initiateBootstrappingRequest

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

適用於