1#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
14pub struct PatchedBulkWirelessLinkRequest {
15 #[serde(rename = "id")]
16 pub id: i32,
17 #[serde(rename = "interface_a", skip_serializing_if = "Option::is_none")]
18 pub interface_a: Option<Box<crate::models::BulkVirtualCircuitTerminationRequestInterface>>,
19 #[serde(rename = "interface_b", skip_serializing_if = "Option::is_none")]
20 pub interface_b: Option<Box<crate::models::BulkVirtualCircuitTerminationRequestInterface>>,
21 #[serde(rename = "ssid", skip_serializing_if = "Option::is_none")]
22 pub ssid: Option<String>,
23 #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
25 pub status: Option<Status>,
26 #[serde(
27 rename = "tenant",
28 default,
29 with = "::serde_with::rust::double_option",
30 skip_serializing_if = "Option::is_none"
31 )]
32 pub tenant: Option<Option<Box<crate::models::AsnRangeRequestTenant>>>,
33 #[serde(rename = "auth_type", skip_serializing_if = "Option::is_none")]
35 pub auth_type: Option<AuthType>,
36 #[serde(rename = "auth_cipher", skip_serializing_if = "Option::is_none")]
38 pub auth_cipher: Option<AuthCipher>,
39 #[serde(rename = "auth_psk", skip_serializing_if = "Option::is_none")]
40 pub auth_psk: Option<String>,
41 #[serde(
42 rename = "distance",
43 default,
44 with = "::serde_with::rust::double_option",
45 skip_serializing_if = "Option::is_none"
46 )]
47 pub distance: Option<Option<f64>>,
48 #[serde(
50 rename = "distance_unit",
51 default,
52 with = "::serde_with::rust::double_option",
53 skip_serializing_if = "Option::is_none"
54 )]
55 pub distance_unit: Option<Option<DistanceUnit>>,
56 #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
57 pub description: Option<String>,
58 #[serde(
59 rename = "owner",
60 default,
61 with = "::serde_with::rust::double_option",
62 skip_serializing_if = "Option::is_none"
63 )]
64 pub owner: Option<Option<Box<crate::models::AsnRangeRequestOwner>>>,
65 #[serde(rename = "comments", skip_serializing_if = "Option::is_none")]
66 pub comments: Option<String>,
67 #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
68 pub tags: Option<Vec<crate::models::NestedTagRequest>>,
69 #[serde(rename = "custom_fields", skip_serializing_if = "Option::is_none")]
70 pub custom_fields: Option<::std::collections::HashMap<String, serde_json::Value>>,
71}
72
73impl PatchedBulkWirelessLinkRequest {
74 pub fn new(id: i32) -> PatchedBulkWirelessLinkRequest {
76 PatchedBulkWirelessLinkRequest {
77 id,
78 interface_a: None,
79 interface_b: None,
80 ssid: None,
81 status: None,
82 tenant: None,
83 auth_type: None,
84 auth_cipher: None,
85 auth_psk: None,
86 distance: None,
87 distance_unit: None,
88 description: None,
89 owner: None,
90 comments: None,
91 tags: None,
92 custom_fields: None,
93 }
94 }
95}
96
97#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
99pub enum Status {
100 #[serde(rename = "connected")]
101 Connected,
102 #[serde(rename = "planned")]
103 Planned,
104 #[serde(rename = "decommissioning")]
105 Decommissioning,
106}
107
108impl Default for Status {
109 fn default() -> Status {
110 Self::Connected
111 }
112}
113#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
115pub enum AuthType {
116 #[serde(rename = "open")]
117 Open,
118 #[serde(rename = "wep")]
119 Wep,
120 #[serde(rename = "wpa-personal")]
121 WpaPersonal,
122 #[serde(rename = "wpa-enterprise")]
123 WpaEnterprise,
124 #[serde(rename = "")]
125 Empty,
126}
127
128impl Default for AuthType {
129 fn default() -> AuthType {
130 Self::Open
131 }
132}
133#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
135pub enum AuthCipher {
136 #[serde(rename = "auto")]
137 Auto,
138 #[serde(rename = "tkip")]
139 Tkip,
140 #[serde(rename = "aes")]
141 Aes,
142 #[serde(rename = "")]
143 Empty,
144}
145
146impl Default for AuthCipher {
147 fn default() -> AuthCipher {
148 Self::Auto
149 }
150}
151#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
153pub enum DistanceUnit {
154 #[serde(rename = "km")]
155 Km,
156 #[serde(rename = "m")]
157 M,
158 #[serde(rename = "mi")]
159 Mi,
160 #[serde(rename = "ft")]
161 Ft,
162 #[serde(rename = "")]
163 Empty,
164 #[serde(rename = "null")]
165 Null,
166}
167
168impl Default for DistanceUnit {
169 fn default() -> DistanceUnit {
170 Self::Km
171 }
172}