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

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

        /// [onCreateActionView](https://developer.android.com/reference/android/view/ActionProvider.html#onCreateActionView())
        ///
        /// Required features: "android-view-View"
        #[cfg(any(feature = "all", all(feature = "android-view-View")))]
        #[deprecated] pub fn onCreateActionView<'env>(&'env self) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::view::View>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/view/ActionProvider", java.flags == PUBLIC | ABSTRACT, .name == "onCreateActionView", .descriptor == "()Landroid/view/View;"
            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/view/ActionProvider\0", "onCreateActionView\0", "()Landroid/view/View;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

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

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

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

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

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

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

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

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