netbox_openapi/models/
location_status.rs1#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
12pub struct LocationStatus {
13 #[serde(rename = "value", skip_serializing_if = "Option::is_none")]
15 pub value: Option<Value>,
16 #[serde(rename = "label", skip_serializing_if = "Option::is_none")]
17 pub label: Option<Label>,
18}
19
20impl LocationStatus {
21 pub fn new() -> LocationStatus {
22 LocationStatus {
23 value: None,
24 label: None,
25 }
26 }
27}
28
29#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
31pub enum Value {
32 #[serde(rename = "planned")]
33 Planned,
34 #[serde(rename = "staging")]
35 Staging,
36 #[serde(rename = "active")]
37 Active,
38 #[serde(rename = "decommissioning")]
39 Decommissioning,
40 #[serde(rename = "retired")]
41 Retired,
42}
43
44impl Default for Value {
45 fn default() -> Value {
46 Self::Planned
47 }
48}
49#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
51pub enum Label {
52 #[serde(rename = "Planned")]
53 Planned,
54 #[serde(rename = "Staging")]
55 Staging,
56 #[serde(rename = "Active")]
57 Active,
58 #[serde(rename = "Decommissioning")]
59 Decommissioning,
60 #[serde(rename = "Retired")]
61 Retired,
62}
63
64impl Default for Label {
65 fn default() -> Label {
66 Self::Planned
67 }
68}