#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct RackAirflow {
#[serde(rename = "value", skip_serializing_if = "Option::is_none")]
pub value: Option<Value>,
#[serde(rename = "label", skip_serializing_if = "Option::is_none")]
pub label: Option<Label>,
}
impl RackAirflow {
pub fn new() -> RackAirflow {
RackAirflow {
value: None,
label: None,
}
}
}
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Value {
#[serde(rename = "front-to-rear")]
FrontToRear,
#[serde(rename = "rear-to-front")]
RearToFront,
#[serde(rename = "")]
Empty,
}
impl Default for Value {
fn default() -> Value {
Self::FrontToRear
}
}
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Label {
#[serde(rename = "Front to rear")]
FrontToRear,
#[serde(rename = "Rear to front")]
RearToFront,
}
impl Default for Label {
fn default() -> Label {
Self::FrontToRear
}
}