Lenguaje

BluetoothGattServerCallback.OnCharacteristicReadRequest Método

Definición

Un cliente remoto ha solicitado leer una característica local.

[Android.Runtime.Register("onCharacteristicReadRequest", "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattCharacteristic;)V", "GetOnCharacteristicReadRequest_Landroid_bluetooth_BluetoothDevice_IILandroid_bluetooth_BluetoothGattCharacteristic_Handler")]
public virtual void OnCharacteristicReadRequest(Android.Bluetooth.BluetoothDevice? device, int requestId, int offset, Android.Bluetooth.BluetoothGattCharacteristic? characteristic);
[<Android.Runtime.Register("onCharacteristicReadRequest", "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattCharacteristic;)V", "GetOnCharacteristicReadRequest_Landroid_bluetooth_BluetoothDevice_IILandroid_bluetooth_BluetoothGattCharacteristic_Handler")>]
abstract member OnCharacteristicReadRequest : Android.Bluetooth.BluetoothDevice * int * int * Android.Bluetooth.BluetoothGattCharacteristic -> unit
override this.OnCharacteristicReadRequest : Android.Bluetooth.BluetoothDevice * int * int * Android.Bluetooth.BluetoothGattCharacteristic -> unit

Parámetros

device
BluetoothDevice

Dispositivo remoto que ha solicitado la operación de lectura

requestId
Int32

Identificador de la solicitud

offset
Int32

Desplazamiento en el valor de la característica

characteristic
BluetoothGattCharacteristic

Característica que se va a leer

Atributos

Comentarios

Un cliente remoto ha solicitado leer una característica local.

Una aplicación debe llamar BluetoothGattServer#sendResponse a para completar la solicitud.

Java documentación para android.bluetooth.BluetoothGattServerCallback.onCharacteristicReadRequest(android.bluetooth.BluetoothDevice, int, int, android.bluetooth.BluetoothGattCharacteristic).

Las partes de esta página son modificaciones basadas en el trabajo creado y compartido por el Android y se usan según los términos descritos en creative Creative Commons 2.5 Attribution License.

Se aplica a