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 = "org-apache-http-HttpVersion"))]
__jni_bindgen! {
    /// public final class [HttpVersion](https://developer.android.com/reference/org/apache/http/HttpVersion.html)
    ///
    /// Required feature: "org-apache-http-HttpVersion"
    public final class HttpVersion ("org/apache/http/HttpVersion") extends crate::org::apache::http::ProtocolVersion, implements crate::java::io::Serializable {

        /// [HttpVersion](https://developer.android.com/reference/org/apache/http/HttpVersion.html#HttpVersion(int,%20int))
        pub fn new<'env>(__jni_env: &'env __jni_bindgen::Env, arg0: i32, arg1: i32) -> __jni_bindgen::std::result::Result<__jni_bindgen::Local<'env, crate::org::apache::http::HttpVersion>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "org/apache/http/HttpVersion", java.flags == PUBLIC, .name == "<init>", .descriptor == "(II)V"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0), __jni_bindgen::AsJValue::as_jvalue(&arg1)];
                let (__jni_class, __jni_method) = __jni_env.require_class_method("org/apache/http/HttpVersion\0", "<init>\0", "(II)V\0");
                __jni_env.new_object_a(__jni_class, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [forVersion](https://developer.android.com/reference/org/apache/http/HttpVersion.html#forVersion(int,%20int))
        ///
        /// Required features: "org-apache-http-ProtocolVersion"
        #[cfg(any(feature = "all", all(feature = "org-apache-http-ProtocolVersion")))]
        pub fn forVersion<'env>(&'env self, arg0: i32, arg1: i32) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::org::apache::http::ProtocolVersion>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "org/apache/http/HttpVersion", java.flags == PUBLIC, .name == "forVersion", .descriptor == "(II)Lorg/apache/http/ProtocolVersion;"
            unsafe {
                let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0), __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("org/apache/http/HttpVersion\0", "forVersion\0", "(II)Lorg/apache/http/ProtocolVersion;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// public static final [HTTP](https://developer.android.com/reference/org/apache/http/HttpVersion.html#HTTP)
        pub const HTTP : &'static str = "HTTP";

        /// **get** public static final [HTTP_0_9](https://developer.android.com/reference/org/apache/http/HttpVersion.html#HTTP_0_9)
        ///
        /// Required feature: "org-apache-http-HttpVersion"
        #[cfg(any(feature = "all", feature = "org-apache-http-HttpVersion"))]
        pub fn HTTP_0_9<'env>(env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::org::apache::http::HttpVersion>> {
            unsafe {
                let (__jni_class, __jni_field) = env.require_class_static_field("org/apache/http/HttpVersion\0", "HTTP_0_9\0", "Lorg/apache/http/HttpVersion;\0");
                env.get_static_object_field(__jni_class, __jni_field)
            }
        }

        /// **get** public static final [HTTP_1_0](https://developer.android.com/reference/org/apache/http/HttpVersion.html#HTTP_1_0)
        ///
        /// Required feature: "org-apache-http-HttpVersion"
        #[cfg(any(feature = "all", feature = "org-apache-http-HttpVersion"))]
        pub fn HTTP_1_0<'env>(env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::org::apache::http::HttpVersion>> {
            unsafe {
                let (__jni_class, __jni_field) = env.require_class_static_field("org/apache/http/HttpVersion\0", "HTTP_1_0\0", "Lorg/apache/http/HttpVersion;\0");
                env.get_static_object_field(__jni_class, __jni_field)
            }
        }

        /// **get** public static final [HTTP_1_1](https://developer.android.com/reference/org/apache/http/HttpVersion.html#HTTP_1_1)
        ///
        /// Required feature: "org-apache-http-HttpVersion"
        #[cfg(any(feature = "all", feature = "org-apache-http-HttpVersion"))]
        pub fn HTTP_1_1<'env>(env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::org::apache::http::HttpVersion>> {
            unsafe {
                let (__jni_class, __jni_field) = env.require_class_static_field("org/apache/http/HttpVersion\0", "HTTP_1_1\0", "Lorg/apache/http/HttpVersion;\0");
                env.get_static_object_field(__jni_class, __jni_field)
            }
        }
    }
}