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-app-KeyguardManager"))]
__jni_bindgen! {
    /// public class [KeyguardManager](https://developer.android.com/reference/android/app/KeyguardManager.html)
    ///
    /// Required feature: "android-app-KeyguardManager"
    public class KeyguardManager ("android/app/KeyguardManager") extends crate::java::lang::Object {

        /// [createConfirmDeviceCredentialIntent](https://developer.android.com/reference/android/app/KeyguardManager.html#createConfirmDeviceCredentialIntent(java.lang.CharSequence,%20java.lang.CharSequence))
        ///
        /// Required features: "android-content-Intent", "java-lang-CharSequence"
        #[cfg(any(feature = "all", all(feature = "android-content-Intent", feature = "java-lang-CharSequence")))]
        pub fn createConfirmDeviceCredentialIntent<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::CharSequence>>, arg1: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::CharSequence>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::content::Intent>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "createConfirmDeviceCredentialIntent", .descriptor == "(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Landroid/content/Intent;"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0.into()), __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/app/KeyguardManager\0", "createConfirmDeviceCredentialIntent\0", "(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Landroid/content/Intent;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [newKeyguardLock](https://developer.android.com/reference/android/app/KeyguardManager.html#newKeyguardLock(java.lang.String))
        ///
        /// Required features: "android-app-KeyguardManager_KeyguardLock", "java-lang-String"
        #[cfg(any(feature = "all", all(feature = "android-app-KeyguardManager_KeyguardLock", feature = "java-lang-String")))]
        #[deprecated] pub fn newKeyguardLock<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::String>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::app::KeyguardManager_KeyguardLock>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "newKeyguardLock", .descriptor == "(Ljava/lang/String;)Landroid/app/KeyguardManager$KeyguardLock;"
            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/app/KeyguardManager\0", "newKeyguardLock\0", "(Ljava/lang/String;)Landroid/app/KeyguardManager$KeyguardLock;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [isKeyguardLocked](https://developer.android.com/reference/android/app/KeyguardManager.html#isKeyguardLocked())
        pub fn isKeyguardLocked<'env>(&'env self) -> __jni_bindgen::std::result::Result<bool, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "isKeyguardLocked", .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/app/KeyguardManager\0", "isKeyguardLocked\0", "()Z\0");
                __jni_env.call_boolean_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [isKeyguardSecure](https://developer.android.com/reference/android/app/KeyguardManager.html#isKeyguardSecure())
        pub fn isKeyguardSecure<'env>(&'env self) -> __jni_bindgen::std::result::Result<bool, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "isKeyguardSecure", .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/app/KeyguardManager\0", "isKeyguardSecure\0", "()Z\0");
                __jni_env.call_boolean_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [inKeyguardRestrictedInputMode](https://developer.android.com/reference/android/app/KeyguardManager.html#inKeyguardRestrictedInputMode())
        pub fn inKeyguardRestrictedInputMode<'env>(&'env self) -> __jni_bindgen::std::result::Result<bool, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "inKeyguardRestrictedInputMode", .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/app/KeyguardManager\0", "inKeyguardRestrictedInputMode\0", "()Z\0");
                __jni_env.call_boolean_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [exitKeyguardSecurely](https://developer.android.com/reference/android/app/KeyguardManager.html#exitKeyguardSecurely(android.app.KeyguardManager.OnKeyguardExitResult))
        ///
        /// Required features: "android-app-KeyguardManager_OnKeyguardExitResult"
        #[cfg(any(feature = "all", all(feature = "android-app-KeyguardManager_OnKeyguardExitResult")))]
        #[deprecated] pub fn exitKeyguardSecurely<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::android::app::KeyguardManager_OnKeyguardExitResult>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/app/KeyguardManager", java.flags == PUBLIC, .name == "exitKeyguardSecurely", .descriptor == "(Landroid/app/KeyguardManager$OnKeyguardExitResult;)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/app/KeyguardManager\0", "exitKeyguardSecurely\0", "(Landroid/app/KeyguardManager$OnKeyguardExitResult;)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }
    }
}