// WARNING: This file was autogenerated by jni-bindgen. Any changes to this file may be lost!!!
#[cfg(any(feature = "all", feature = "android-bluetooth-BluetoothGattServerCallback"))]
__jni_bindgen! {
/// public class [BluetoothGattServerCallback](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html)
///
/// Required feature: "android-bluetooth-BluetoothGattServerCallback"
public class BluetoothGattServerCallback ("android/bluetooth/BluetoothGattServerCallback") extends crate::java::lang::Object {
/// [BluetoothGattServerCallback](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#BluetoothGattServerCallback())
pub fn new<'env>(__jni_env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::result::Result<__jni_bindgen::Local<'env, crate::android::bluetooth::BluetoothGattServerCallback>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "<init>", .descriptor == "()V"
unsafe {
let __jni_args = [];
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "<init>\0", "()V\0");
__jni_env.new_object_a(__jni_class, __jni_method, __jni_args.as_ptr())
}
}
/// [onConnectionStateChange](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onConnectionStateChange(android.bluetooth.BluetoothDevice,%20int,%20int))
///
/// Required features: "android-bluetooth-BluetoothDevice"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice")))]
pub fn onConnectionStateChange<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: i32) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onConnectionStateChange", .descriptor == "(Landroid/bluetooth/BluetoothDevice;II)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onConnectionStateChange\0", "(Landroid/bluetooth/BluetoothDevice;II)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onServiceAdded](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onServiceAdded(int,%20android.bluetooth.BluetoothGattService))
///
/// Required features: "android-bluetooth-BluetoothGattService"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothGattService")))]
pub fn onServiceAdded<'env>(&'env self, arg0: i32, arg1: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothGattService>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onServiceAdded", .descriptor == "(ILandroid/bluetooth/BluetoothGattService;)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0), __jni_bindgen::AsJValue::as_jvalue(&arg1.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onServiceAdded\0", "(ILandroid/bluetooth/BluetoothGattService;)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onCharacteristicReadRequest](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onCharacteristicReadRequest(android.bluetooth.BluetoothDevice,%20int,%20int,%20android.bluetooth.BluetoothGattCharacteristic))
///
/// Required features: "android-bluetooth-BluetoothDevice", "android-bluetooth-BluetoothGattCharacteristic"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice", feature = "android-bluetooth-BluetoothGattCharacteristic")))]
pub fn onCharacteristicReadRequest<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: i32, arg3: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothGattCharacteristic>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onCharacteristicReadRequest", .descriptor == "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattCharacteristic;)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2), __jni_bindgen::AsJValue::as_jvalue(&arg3.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onCharacteristicReadRequest\0", "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattCharacteristic;)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onCharacteristicWriteRequest](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onCharacteristicWriteRequest(android.bluetooth.BluetoothDevice,%20int,%20android.bluetooth.BluetoothGattCharacteristic,%20boolean,%20boolean,%20int,%20byte%5B%5D))
///
/// Required features: "android-bluetooth-BluetoothDevice", "android-bluetooth-BluetoothGattCharacteristic"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice", feature = "android-bluetooth-BluetoothGattCharacteristic")))]
pub fn onCharacteristicWriteRequest<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothGattCharacteristic>>, arg3: bool, arg4: bool, arg5: i32, arg6: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env __jni_bindgen::ByteArray>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onCharacteristicWriteRequest", .descriptor == "(Landroid/bluetooth/BluetoothDevice;ILandroid/bluetooth/BluetoothGattCharacteristic;ZZI[B)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2.into()), __jni_bindgen::AsJValue::as_jvalue(&arg3), __jni_bindgen::AsJValue::as_jvalue(&arg4), __jni_bindgen::AsJValue::as_jvalue(&arg5), __jni_bindgen::AsJValue::as_jvalue(&arg6.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onCharacteristicWriteRequest\0", "(Landroid/bluetooth/BluetoothDevice;ILandroid/bluetooth/BluetoothGattCharacteristic;ZZI[B)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onDescriptorReadRequest](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onDescriptorReadRequest(android.bluetooth.BluetoothDevice,%20int,%20int,%20android.bluetooth.BluetoothGattDescriptor))
///
/// Required features: "android-bluetooth-BluetoothDevice", "android-bluetooth-BluetoothGattDescriptor"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice", feature = "android-bluetooth-BluetoothGattDescriptor")))]
pub fn onDescriptorReadRequest<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: i32, arg3: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothGattDescriptor>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onDescriptorReadRequest", .descriptor == "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattDescriptor;)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2), __jni_bindgen::AsJValue::as_jvalue(&arg3.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onDescriptorReadRequest\0", "(Landroid/bluetooth/BluetoothDevice;IILandroid/bluetooth/BluetoothGattDescriptor;)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onDescriptorWriteRequest](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onDescriptorWriteRequest(android.bluetooth.BluetoothDevice,%20int,%20android.bluetooth.BluetoothGattDescriptor,%20boolean,%20boolean,%20int,%20byte%5B%5D))
///
/// Required features: "android-bluetooth-BluetoothDevice", "android-bluetooth-BluetoothGattDescriptor"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice", feature = "android-bluetooth-BluetoothGattDescriptor")))]
pub fn onDescriptorWriteRequest<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothGattDescriptor>>, arg3: bool, arg4: bool, arg5: i32, arg6: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env __jni_bindgen::ByteArray>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onDescriptorWriteRequest", .descriptor == "(Landroid/bluetooth/BluetoothDevice;ILandroid/bluetooth/BluetoothGattDescriptor;ZZI[B)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2.into()), __jni_bindgen::AsJValue::as_jvalue(&arg3), __jni_bindgen::AsJValue::as_jvalue(&arg4), __jni_bindgen::AsJValue::as_jvalue(&arg5), __jni_bindgen::AsJValue::as_jvalue(&arg6.into())];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onDescriptorWriteRequest\0", "(Landroid/bluetooth/BluetoothDevice;ILandroid/bluetooth/BluetoothGattDescriptor;ZZI[B)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onExecuteWrite](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onExecuteWrite(android.bluetooth.BluetoothDevice,%20int,%20boolean))
///
/// Required features: "android-bluetooth-BluetoothDevice"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice")))]
pub fn onExecuteWrite<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32, arg2: bool) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onExecuteWrite", .descriptor == "(Landroid/bluetooth/BluetoothDevice;IZ)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1), __jni_bindgen::AsJValue::as_jvalue(&arg2)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onExecuteWrite\0", "(Landroid/bluetooth/BluetoothDevice;IZ)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [onNotificationSent](https://developer.android.com/reference/android/bluetooth/BluetoothGattServerCallback.html#onNotificationSent(android.bluetooth.BluetoothDevice,%20int))
///
/// Required features: "android-bluetooth-BluetoothDevice"
#[cfg(any(feature = "all", all(feature = "android-bluetooth-BluetoothDevice")))]
pub fn onNotificationSent<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::bluetooth::BluetoothDevice>>, arg1: i32) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "android/bluetooth/BluetoothGattServerCallback", java.flags == PUBLIC, .name == "onNotificationSent", .descriptor == "(Landroid/bluetooth/BluetoothDevice;I)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __jni_bindgen::AsJValue::as_jvalue(&arg1)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("android/bluetooth/BluetoothGattServerCallback\0", "onNotificationSent\0", "(Landroid/bluetooth/BluetoothDevice;I)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
}
}