jni-android-sys 0.0.10

Autogenerated glue code for access Android JVM APIs from Rust
// WARNING:  This file was autogenerated by jni-bindgen.  Any changes to this file may be lost!!!


#[cfg(any(feature = "all", feature = "android-telecom-InCallService"))]
__jni_bindgen! {
    /// public class [InCallService](https://developer.android.com/reference/android/telecom/InCallService.html)
    ///
    /// Required feature: "android-telecom-InCallService"
    public class InCallService ("android/telecom/InCallService") extends crate::android::app::Service {

        /// [InCallService](https://developer.android.com/reference/android/telecom/InCallService.html#InCallService())
        pub fn new<'env>(__jni_env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::result::Result<__jni_bindgen::Local<'env, crate::android::telecom::InCallService>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "<init>", .descriptor == "()V"
            unsafe {
                let __jni_args = [];
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "<init>\0", "()V\0");
                __jni_env.new_object_a(__jni_class, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onBind](https://developer.android.com/reference/android/telecom/InCallService.html#onBind(android.content.Intent))
        ///
        /// Required features: "android-content-Intent", "android-os-IBinder"
        #[cfg(any(feature = "all", all(feature = "android-content-Intent", feature = "android-os-IBinder")))]
        pub fn onBind<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::content::Intent>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::os::IBinder>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onBind", .descriptor == "(Landroid/content/Intent;)Landroid/os/IBinder;"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onBind\0", "(Landroid/content/Intent;)Landroid/os/IBinder;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onUnbind](https://developer.android.com/reference/android/telecom/InCallService.html#onUnbind(android.content.Intent))
        ///
        /// Required features: "android-content-Intent"
        #[cfg(any(feature = "all", all(feature = "android-content-Intent")))]
        pub fn onUnbind<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::content::Intent>>) -> __jni_bindgen::std::result::Result<bool, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onUnbind", .descriptor == "(Landroid/content/Intent;)Z"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onUnbind\0", "(Landroid/content/Intent;)Z\0");
                __jni_env.call_boolean_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [getCalls](https://developer.android.com/reference/android/telecom/InCallService.html#getCalls())
        ///
        /// Required features: "java-util-List"
        #[cfg(any(feature = "all", all(feature = "java-util-List")))]
        pub fn getCalls<'env>(&'env self) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::util::List>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC | FINAL, .name == "getCalls", .descriptor == "()Ljava/util/List;"
            unsafe {
                let __jni_args = [];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "getCalls\0", "()Ljava/util/List;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [canAddCall](https://developer.android.com/reference/android/telecom/InCallService.html#canAddCall())
        pub fn canAddCall<'env>(&'env self) -> __jni_bindgen::std::result::Result<bool, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC | FINAL, .name == "canAddCall", .descriptor == "()Z"
            unsafe {
                let __jni_args = [];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "canAddCall\0", "()Z\0");
                __jni_env.call_boolean_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [getCallAudioState](https://developer.android.com/reference/android/telecom/InCallService.html#getCallAudioState())
        ///
        /// Required features: "android-telecom-CallAudioState"
        #[cfg(any(feature = "all", all(feature = "android-telecom-CallAudioState")))]
        pub fn getCallAudioState<'env>(&'env self) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::telecom::CallAudioState>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC | FINAL, .name == "getCallAudioState", .descriptor == "()Landroid/telecom/CallAudioState;"
            unsafe {
                let __jni_args = [];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "getCallAudioState\0", "()Landroid/telecom/CallAudioState;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [setMuted](https://developer.android.com/reference/android/telecom/InCallService.html#setMuted(boolean))
        pub fn setMuted<'env>(&'env self, arg0: bool) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC | FINAL, .name == "setMuted", .descriptor == "(Z)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "setMuted\0", "(Z)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [setAudioRoute](https://developer.android.com/reference/android/telecom/InCallService.html#setAudioRoute(int))
        pub fn setAudioRoute<'env>(&'env self, arg0: i32) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC | FINAL, .name == "setAudioRoute", .descriptor == "(I)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "setAudioRoute\0", "(I)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onCallAudioStateChanged](https://developer.android.com/reference/android/telecom/InCallService.html#onCallAudioStateChanged(android.telecom.CallAudioState))
        ///
        /// Required features: "android-telecom-CallAudioState"
        #[cfg(any(feature = "all", all(feature = "android-telecom-CallAudioState")))]
        pub fn onCallAudioStateChanged<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::telecom::CallAudioState>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onCallAudioStateChanged", .descriptor == "(Landroid/telecom/CallAudioState;)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onCallAudioStateChanged\0", "(Landroid/telecom/CallAudioState;)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onBringToForeground](https://developer.android.com/reference/android/telecom/InCallService.html#onBringToForeground(boolean))
        pub fn onBringToForeground<'env>(&'env self, arg0: bool) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onBringToForeground", .descriptor == "(Z)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onBringToForeground\0", "(Z)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onCallAdded](https://developer.android.com/reference/android/telecom/InCallService.html#onCallAdded(android.telecom.Call))
        ///
        /// Required features: "android-telecom-Call"
        #[cfg(any(feature = "all", all(feature = "android-telecom-Call")))]
        pub fn onCallAdded<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::telecom::Call>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onCallAdded", .descriptor == "(Landroid/telecom/Call;)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onCallAdded\0", "(Landroid/telecom/Call;)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onCallRemoved](https://developer.android.com/reference/android/telecom/InCallService.html#onCallRemoved(android.telecom.Call))
        ///
        /// Required features: "android-telecom-Call"
        #[cfg(any(feature = "all", all(feature = "android-telecom-Call")))]
        pub fn onCallRemoved<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::telecom::Call>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onCallRemoved", .descriptor == "(Landroid/telecom/Call;)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into())];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onCallRemoved\0", "(Landroid/telecom/Call;)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onCanAddCallChanged](https://developer.android.com/reference/android/telecom/InCallService.html#onCanAddCallChanged(boolean))
        pub fn onCanAddCallChanged<'env>(&'env self, arg0: bool) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onCanAddCallChanged", .descriptor == "(Z)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onCanAddCallChanged\0", "(Z)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [onSilenceRinger](https://developer.android.com/reference/android/telecom/InCallService.html#onSilenceRinger())
        pub fn onSilenceRinger<'env>(&'env self) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/telecom/InCallService", java.flags == PUBLIC, .name == "onSilenceRinger", .descriptor == "()V"
            unsafe {
                let __jni_args = [];
                let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_method) = __jni_env.require_class_method("android/telecom/InCallService\0", "onSilenceRinger\0", "()V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// public static final [SERVICE_INTERFACE](https://developer.android.com/reference/android/telecom/InCallService.html#SERVICE_INTERFACE)
        pub const SERVICE_INTERFACE : &'static str = "android.telecom.InCallService";
    }
}