BluetoothDevice.GetEncryptionStatus(Int32) 方法

定义

获取连接的设备的加密状态。

[Android.Runtime.Register("getEncryptionStatus", "(I)Landroid/bluetooth/EncryptionStatus;", "", ApiSince=36)]
[Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")]
public Android.Bluetooth.EncryptionStatus? GetEncryptionStatus(int transport);
[<Android.Runtime.Register("getEncryptionStatus", "(I)Landroid/bluetooth/EncryptionStatus;", "", ApiSince=36)>]
[<Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")>]
member this.GetEncryptionStatus : int -> Android.Bluetooth.EncryptionStatus

参数

transport
Int32

要获取其链接状态的传输。

返回

设备的加密状态,如果设备未加密或未连接,则为 null。

属性

注解

获取连接的设备的加密状态。 此 API 将返回加密状态(如果已连接)。 加密详细信息包含在一个 EncryptionStatus 对象中,如果设备未加密(或未连接),则该详细信息可以为 null。

Java文档android.bluetooth.BluetoothDevice.getEncryptionStatus(int)

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于