Langue

BluetoothGattServerCallback.OnConnectionStateChange Méthode

Définition

Rappel indiquant quand un appareil distant a été connecté ou déconnecté.

[Android.Runtime.Register("onConnectionStateChange", "(Landroid/bluetooth/BluetoothDevice;II)V", "GetOnConnectionStateChange_Landroid_bluetooth_BluetoothDevice_IIHandler")]
public virtual void OnConnectionStateChange(Android.Bluetooth.BluetoothDevice? device, Android.Bluetooth.ProfileState status, Android.Bluetooth.ProfileState newState);
[<Android.Runtime.Register("onConnectionStateChange", "(Landroid/bluetooth/BluetoothDevice;II)V", "GetOnConnectionStateChange_Landroid_bluetooth_BluetoothDevice_IIHandler")>]
abstract member OnConnectionStateChange : Android.Bluetooth.BluetoothDevice * Android.Bluetooth.ProfileState * Android.Bluetooth.ProfileState -> unit
override this.OnConnectionStateChange : Android.Bluetooth.BluetoothDevice * Android.Bluetooth.ProfileState * Android.Bluetooth.ProfileState -> unit

Paramètres

device
BluetoothDevice

Appareil distant connecté ou déconnecté.

status
ProfileState

État de l’opération de connexion ou de déconnexion.

newState
ProfileState

Retourne le nouvel état de connexion. Peut être l’un des BluetoothProfile#STATE_DISCONNECTED ou BluetoothProfile#STATE_CONNECTED

Attributs

Remarques

Rappel indiquant quand un appareil distant a été connecté ou déconnecté.

Java documentation pour android.bluetooth.BluetoothGattServerCallback.onConnectionStateChange(android.bluetooth.BluetoothDevice, int, int).

Les parties de cette page sont des modifications basées sur le travail créé et partagé par Android Open Source et utilisées en fonction des termes décrits dans la Creative Commons 2.5 Attribution License.

S’applique à