summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--android/src/main/kotlin/net/mullvad/mullvadvpn/model/WireguardEndpointData.kt3
-rw-r--r--mullvad-jni/src/classes.rs1
-rw-r--r--mullvad-types/src/relay_list.rs6
3 files changed, 9 insertions, 1 deletions
diff --git a/android/src/main/kotlin/net/mullvad/mullvadvpn/model/WireguardEndpointData.kt b/android/src/main/kotlin/net/mullvad/mullvadvpn/model/WireguardEndpointData.kt
new file mode 100644
index 0000000000..1d39f1170d
--- /dev/null
+++ b/android/src/main/kotlin/net/mullvad/mullvadvpn/model/WireguardEndpointData.kt
@@ -0,0 +1,3 @@
+package net.mullvad.mullvadvpn.model
+
+class WireguardEndpointData()
diff --git a/mullvad-jni/src/classes.rs b/mullvad-jni/src/classes.rs
index 3aa7d74e3e..c52f58d18c 100644
--- a/mullvad-jni/src/classes.rs
+++ b/mullvad-jni/src/classes.rs
@@ -34,6 +34,7 @@ pub const CLASSES: &[&str] = &[
"net/mullvad/mullvadvpn/model/TunnelState$Connecting",
"net/mullvad/mullvadvpn/model/TunnelState$Disconnected",
"net/mullvad/mullvadvpn/model/TunnelState$Disconnecting",
+ "net/mullvad/mullvadvpn/model/WireguardEndpointData",
"net/mullvad/mullvadvpn/MullvadDaemon",
"net/mullvad/mullvadvpn/MullvadVpnService",
"net/mullvad/talpid/net/Endpoint",
diff --git a/mullvad-types/src/relay_list.rs b/mullvad-types/src/relay_list.rs
index ee87751c43..f5919f5b6d 100644
--- a/mullvad-types/src/relay_list.rs
+++ b/mullvad-types/src/relay_list.rs
@@ -2,7 +2,8 @@ use crate::{
endpoint::MullvadEndpoint,
location::{CityCode, CountryCode, Location},
};
-
+#[cfg(target_os = "android")]
+use jnix::IntoJava;
use serde::{Deserialize, Serialize};
use std::{
fmt,
@@ -95,6 +96,9 @@ impl fmt::Display for OpenVpnEndpointData {
}
#[derive(Clone, Eq, PartialEq, Hash, Deserialize, Serialize, Debug)]
+#[cfg_attr(target_os = "android", derive(IntoJava))]
+#[cfg_attr(target_os = "android", jnix(package = "net.mullvad.mullvadvpn.model"))]
+#[cfg_attr(target_os = "android", jnix(skip_all))]
pub struct WireguardEndpointData {
/// Port to connect to
pub port_ranges: Vec<(u16, u16)>,