BluetoothGattConnectionSettings.Builder.SetAutoConnectEnabled(Boolean) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
如果设置为 true,则会在远程设备可用时启用与远程设备的自动连接。
[Android.Runtime.Register("setAutoConnectEnabled", "(Z)Landroid/bluetooth/BluetoothGattConnectionSettings$Builder;", "", ApiSince=37)]
public Android.Bluetooth.BluetoothGattConnectionSettings.Builder SetAutoConnectEnabled(bool autoConnectEnabled);
[<Android.Runtime.Register("setAutoConnectEnabled", "(Z)Landroid/bluetooth/BluetoothGattConnectionSettings$Builder;", "", ApiSince=37)>]
member this.SetAutoConnectEnabled : bool -> Android.Bluetooth.BluetoothGattConnectionSettings.Builder
参数
- autoConnectEnabled
- Boolean
如果启用自动连接,则为 true;否则为 false。
返回
此生成器。 此值不能为 null。
- 特性
注解
如果设置为 true,则会在远程设备可用时启用与远程设备的自动连接。 将其设置为 False 将触发直接连接到远程设备
Android 参考。android.bluetooth.BluetoothGattConnectionSettings.Builder.setAutoConnectEnabled
本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。