1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
// WARNING:  This file was autogenerated by jni-bindgen.  Any changes to this file may be lost!!!


#[cfg(any(feature = "all", feature = "android-widget-AdapterView_AdapterContextMenuInfo"))]
__jni_bindgen! {
    /// public class [AdapterView.AdapterContextMenuInfo](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html)
    ///
    /// Required feature: "android-widget-AdapterView_AdapterContextMenuInfo"
    public class AdapterView_AdapterContextMenuInfo ("android/widget/AdapterView$AdapterContextMenuInfo") extends crate::java::lang::Object, implements crate::android::view::ContextMenu_ContextMenuInfo {

        /// [AdapterContextMenuInfo](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#AdapterContextMenuInfo(android.view.View,%20int,%20long))
        ///
        /// Required features: "android-view-View"
        #[cfg(any(feature = "all", all(feature = "android-view-View")))]
        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::view::View>>, arg1: i32, arg2: i64) -> __jni_bindgen::std::result::Result<__jni_bindgen::Local<'env, crate::android::widget::AdapterView_AdapterContextMenuInfo>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "android/widget/AdapterView$AdapterContextMenuInfo", java.flags == PUBLIC, .name == "<init>", .descriptor == "(Landroid/view/View;IJ)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_class, __jni_method) = __jni_env.require_class_method("android/widget/AdapterView$AdapterContextMenuInfo\0", "<init>\0", "(Landroid/view/View;IJ)V\0");
                __jni_env.new_object_a(__jni_class, __jni_method, __jni_args.as_ptr())
            }
        }

        /// **get** public [id](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#id)
        pub fn id<'env>(&'env self) -> i64 {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "id\0", "J\0");
                env.get_long_field(self.0.object, __jni_field)
            }
        }

        /// **set** public [id](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#id)
        pub fn set_id<'env>(&'env self, value: i64) {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "id\0", "J\0");
                env.set_long_field(self.0.object, __jni_field, value)
            }
        }

        /// **get** public [position](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#position)
        pub fn position<'env>(&'env self) -> i32 {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "position\0", "I\0");
                env.get_int_field(self.0.object, __jni_field)
            }
        }

        /// **set** public [position](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#position)
        pub fn set_position<'env>(&'env self, value: i32) {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "position\0", "I\0");
                env.set_int_field(self.0.object, __jni_field, value)
            }
        }

        /// **get** public [targetView](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#targetView)
        ///
        /// Required feature: "android-view-View"
        #[cfg(any(feature = "all", feature = "android-view-View"))]
        pub fn targetView<'env>(&'env self) -> __jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::android::view::View>> {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "targetView\0", "Landroid/view/View;\0");
                env.get_object_field(self.0.object, __jni_field)
            }
        }

        /// **set** public [targetView](https://developer.android.com/reference/android/widget/AdapterView.AdapterContextMenuInfo.html#targetView)
        ///
        /// Required feature: "android-view-View"
        #[cfg(any(feature = "all", feature = "android-view-View"))]
        pub fn set_targetView<'env, 'obj>(&'env self, value: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'obj crate::android::view::View>>) {
            unsafe {
                let env = __jni_bindgen::Env::from_ptr(self.0.env);
                let (__jni_class, __jni_field) = env.require_class_field("android/widget/AdapterView$AdapterContextMenuInfo\0", "targetView\0", "Landroid/view/View;\0");
                env.set_object_field(self.0.object, __jni_field, value)
            }
        }
    }
}