Compartir a través de


BluetoothGatt.SetCharacteristicNotification Método

Definición

Habilite o deshabilite las notificaciones o indicaciones de una característica determinada.

[Android.Runtime.Register("setCharacteristicNotification", "(Landroid/bluetooth/BluetoothGattCharacteristic;Z)Z", "")]
[Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")]
public bool SetCharacteristicNotification (Android.Bluetooth.BluetoothGattCharacteristic? characteristic, bool enable);
[<Android.Runtime.Register("setCharacteristicNotification", "(Landroid/bluetooth/BluetoothGattCharacteristic;Z)Z", "")>]
[<Android.Runtime.RequiresPermission("android.permission.BLUETOOTH_CONNECT")>]
member this.SetCharacteristicNotification : Android.Bluetooth.BluetoothGattCharacteristic * bool -> bool

Parámetros

characteristic
BluetoothGattCharacteristic

Característica para la que se habilitan las notificaciones

enable
Boolean

Establézcalo en true para habilitar notificaciones o indicaciones

Devoluciones

true, si el estado de notificación solicitado se estableció correctamente

Atributos

Comentarios

Documentación de Java para android.bluetooth.BluetoothGatt.setCharacteristicNotification(android.bluetooth.BluetoothGattCharacteristic, boolean).

Las partes de esta página son modificaciones basadas en el trabajo creado y compartido por el proyecto de código abierto de Android y se usan según los términos descritos en la licencia de atribución de Creative Commons 2.5.

Se aplica a