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
// WARNING: This file was autogenerated by jni-bindgen. Any changes to this file may be lost!!!
#[cfg(any(feature = "all", feature = "java-net-SocketOptions"))]
__jni_bindgen! {
/// public interface [SocketOptions](https://developer.android.com/reference/java/net/SocketOptions.html)
///
/// Required feature: "java-net-SocketOptions"
public interface SocketOptions ("java/net/SocketOptions") extends crate::java::lang::Object {
/// [getOption](https://developer.android.com/reference/java/net/SocketOptions.html#getOption(int))
///
/// Required features: "java-lang-Object"
#[cfg(any(feature = "all", all(feature = "java-lang-Object")))]
pub fn getOption<'env>(&'env self, arg0: i32) -> __jni_bindgen::std::result::Result<__jni_bindgen::std::option::Option<__jni_bindgen::Local<'env, crate::java::lang::Object>>, __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "java/net/SocketOptions", java.flags == PUBLIC | ABSTRACT, .name == "getOption", .descriptor == "(I)Ljava/lang/Object;"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0)];
let __jni_env = __jni_bindgen::Env::from_ptr(self.0.env);
let (__jni_class, __jni_method) = __jni_env.require_class_method("java/net/SocketOptions\0", "getOption\0", "(I)Ljava/lang/Object;\0");
__jni_env.call_object_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// [setOption](https://developer.android.com/reference/java/net/SocketOptions.html#setOption(int,%20java.lang.Object))
///
/// Required features: "java-lang-Object"
#[cfg(any(feature = "all", all(feature = "java-lang-Object")))]
pub fn setOption<'env>(&'env self, arg0: i32, arg1: impl __jni_bindgen::std::convert::Into<__jni_bindgen::std::option::Option<&'env crate::java::lang::Object>>) -> __jni_bindgen::std::result::Result<(), __jni_bindgen::Local<'env, crate::java::lang::Throwable>> {
// class.path == "java/net/SocketOptions", java.flags == PUBLIC | ABSTRACT, .name == "setOption", .descriptor == "(ILjava/lang/Object;)V"
unsafe {
let __jni_args = [__jni_bindgen::AsJValue::as_jvalue(&arg0), __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("java/net/SocketOptions\0", "setOption\0", "(ILjava/lang/Object;)V\0");
__jni_env.call_void_method_a(self.0.object, __jni_method, __jni_args.as_ptr())
}
}
/// public static final [IP_MULTICAST_IF](https://developer.android.com/reference/java/net/SocketOptions.html#IP_MULTICAST_IF)
pub const IP_MULTICAST_IF : i32 = 16;
/// public static final [IP_MULTICAST_IF2](https://developer.android.com/reference/java/net/SocketOptions.html#IP_MULTICAST_IF2)
pub const IP_MULTICAST_IF2 : i32 = 31;
/// public static final [IP_MULTICAST_LOOP](https://developer.android.com/reference/java/net/SocketOptions.html#IP_MULTICAST_LOOP)
pub const IP_MULTICAST_LOOP : i32 = 18;
/// public static final [IP_TOS](https://developer.android.com/reference/java/net/SocketOptions.html#IP_TOS)
pub const IP_TOS : i32 = 3;
/// public static final [SO_BINDADDR](https://developer.android.com/reference/java/net/SocketOptions.html#SO_BINDADDR)
pub const SO_BINDADDR : i32 = 15;
/// public static final [SO_BROADCAST](https://developer.android.com/reference/java/net/SocketOptions.html#SO_BROADCAST)
pub const SO_BROADCAST : i32 = 32;
/// public static final [SO_KEEPALIVE](https://developer.android.com/reference/java/net/SocketOptions.html#SO_KEEPALIVE)
pub const SO_KEEPALIVE : i32 = 8;
/// public static final [SO_LINGER](https://developer.android.com/reference/java/net/SocketOptions.html#SO_LINGER)
pub const SO_LINGER : i32 = 128;
/// public static final [SO_OOBINLINE](https://developer.android.com/reference/java/net/SocketOptions.html#SO_OOBINLINE)
pub const SO_OOBINLINE : i32 = 4099;
/// public static final [SO_RCVBUF](https://developer.android.com/reference/java/net/SocketOptions.html#SO_RCVBUF)
pub const SO_RCVBUF : i32 = 4098;
/// public static final [SO_REUSEADDR](https://developer.android.com/reference/java/net/SocketOptions.html#SO_REUSEADDR)
pub const SO_REUSEADDR : i32 = 4;
/// public static final [SO_SNDBUF](https://developer.android.com/reference/java/net/SocketOptions.html#SO_SNDBUF)
pub const SO_SNDBUF : i32 = 4097;
/// public static final [SO_TIMEOUT](https://developer.android.com/reference/java/net/SocketOptions.html#SO_TIMEOUT)
pub const SO_TIMEOUT : i32 = 4102;
/// public static final [TCP_NODELAY](https://developer.android.com/reference/java/net/SocketOptions.html#TCP_NODELAY)
pub const TCP_NODELAY : i32 = 1;
}
}