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-client-CredentialsProvider"))]
__jni_bindgen! {
    /// public interface [CredentialsProvider](https://developer.android.com/reference/org/apache/http/client/CredentialsProvider.html)
    ///
    /// Required feature: "org-apache-http-client-CredentialsProvider"
    #[deprecated] public interface CredentialsProvider ("org/apache/http/client/CredentialsProvider") extends crate::java::lang::Object {

        /// [setCredentials](https://developer.android.com/reference/org/apache/http/client/CredentialsProvider.html#setCredentials(org.apache.http.auth.AuthScope,%20org.apache.http.auth.Credentials))
        ///
        /// Required features: "org-apache-http-auth-AuthScope", "org-apache-http-auth-Credentials"
        #[cfg(any(feature = "all", all(feature = "org-apache-http-auth-AuthScope", feature = "org-apache-http-auth-Credentials")))]
        pub fn setCredentials<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::org::apache::http::auth::AuthScope>>, arg1: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::org::apache::http::auth::Credentials>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "org/apache/http/client/CredentialsProvider", java.flags == PUBLIC | ABSTRACT, .name == "setCredentials", .descriptor == "(Lorg/apache/http/auth/AuthScope;Lorg/apache/http/auth/Credentials;)V"
            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("org/apache/http/client/CredentialsProvider\0", "setCredentials\0", "(Lorg/apache/http/auth/AuthScope;Lorg/apache/http/auth/Credentials;)V\0");
                __jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [getCredentials](https://developer.android.com/reference/org/apache/http/client/CredentialsProvider.html#getCredentials(org.apache.http.auth.AuthScope))
        ///
        /// Required features: "org-apache-http-auth-AuthScope", "org-apache-http-auth-Credentials"
        #[cfg(any(feature = "all", all(feature = "org-apache-http-auth-AuthScope", feature = "org-apache-http-auth-Credentials")))]
        pub fn getCredentials<'env>(&'env self, arg0: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::org::apache::http::auth::AuthScope>>) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::org::apache::http::auth::Credentials>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "org/apache/http/client/CredentialsProvider", java.flags == PUBLIC | ABSTRACT, .name == "getCredentials", .descriptor == "(Lorg/apache/http/auth/AuthScope;)Lorg/apache/http/auth/Credentials;"
            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("org/apache/http/client/CredentialsProvider\0", "getCredentials\0", "(Lorg/apache/http/auth/AuthScope;)Lorg/apache/http/auth/Credentials;\0");
                __jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

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