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 = "java-nio-channels-ServerSocketChannel"))]
__jni_bindgen! {
    /// public class [ServerSocketChannel](https://developer.android.com/reference/java/nio/channels/ServerSocketChannel.html)
    ///
    /// Required feature: "java-nio-channels-ServerSocketChannel"
    public class ServerSocketChannel ("java/nio/channels/ServerSocketChannel") extends crate::java::nio::channels::spi::AbstractSelectableChannel {

        /// [open](https://developer.android.com/reference/java/nio/channels/ServerSocketChannel.html#open())
        ///
        /// Required features: "java-nio-channels-ServerSocketChannel"
        #[cfg(any(feature = "all", all(feature = "java-nio-channels-ServerSocketChannel")))]
        pub fn open<'env>(__jni_env: &'env __jni_bindgen::Env) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::nio::channels::ServerSocketChannel>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "java/nio/channels/ServerSocketChannel", java.flags == PUBLIC | STATIC, .name == "open", .descriptor == "()Ljava/nio/channels/ServerSocketChannel;"
            unsafe {
                let __jni_args = [];
                let (__jni_class, __jni_method) = __jni_env.require_class_static_method("java/nio/channels/ServerSocketChannel\0", "open\0", "()Ljava/nio/channels/ServerSocketChannel;\0");
                __jni_env.call_static_object_method_a(__jni_class, __jni_method, __jni_args.as_ptr())
            }
        }

        /// [validOps](https://developer.android.com/reference/java/nio/channels/ServerSocketChannel.html#validOps())
        pub fn validOps<'env>(&'env self) -> __jni_bindgen::std::result::Result<i32, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
            // class.path == "java/nio/channels/ServerSocketChannel", java.flags == PUBLIC | FINAL, .name == "validOps", .descriptor == "()I"
            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("java/nio/channels/ServerSocketChannel\0", "validOps\0", "()I\0");
                __jni_env.call_int_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
            }
        }

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

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