語言

BluetoothGattCallback.OnMtuChanged(BluetoothGatt, Int32, GattStatus) 方法

定義

回撥指示特定裝置連線的 MTU 已經改變。

[Android.Runtime.Register("onMtuChanged", "(Landroid/bluetooth/BluetoothGatt;II)V", "GetOnMtuChanged_Landroid_bluetooth_BluetoothGatt_IIHandler")]
public virtual void OnMtuChanged(Android.Bluetooth.BluetoothGatt? gatt, int mtu, Android.Bluetooth.GattStatus status);
[<Android.Runtime.Register("onMtuChanged", "(Landroid/bluetooth/BluetoothGatt;II)V", "GetOnMtuChanged_Landroid_bluetooth_BluetoothGatt_IIHandler")>]
abstract member OnMtuChanged : Android.Bluetooth.BluetoothGatt * int * Android.Bluetooth.GattStatus -> unit
override this.OnMtuChanged : Android.Bluetooth.BluetoothGatt * int * Android.Bluetooth.GattStatus -> unit

參數

gatt
BluetoothGatt

呼叫的 GATT 用戶端 BluetoothGatt#requestMtu

mtu
Int32

新的MTU尺寸

status
GattStatus

BluetoothGatt#GATT_SUCCESS 如果MTU已經成功更改

屬性

備註

回撥指示特定裝置連線的 MTU 已經改變。

此回調是回應 BluetoothGatt#requestMtu 函式或連線事件時觸發的。

Java 文件 android.bluetooth.BluetoothGattCallback.onMtuChanged(android.bluetooth.BluetoothGatt, int, int)。

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於