redfish-codegen 0.3.1

An unopinionated translation of the Redfish specification into Rust.
Documentation
// Generated by redfish-codegen. Do not modify.


/// Border Gateway Protocol (BGP) max prefix properties.
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]
#[derive(derivative::Derivative)]
#[derivative(Default)]
pub struct MaxPrefix {
    /// Maximum prefix number.
    #[serde(rename = "MaxPrefixNumber")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub max_prefix_number: Option<i64>,
    /// Border Gateway Protocol (BGP) restart timer in seconds.
    #[serde(rename = "RestartTimerSeconds")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub restart_timer_seconds: Option<i64>,
    /// Shutdown threshold status.
    #[serde(rename = "ShutdownThresholdPercentage")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub shutdown_threshold_percentage: Option<f64>,
    /// Threshold warning only status.
    #[serde(rename = "ThresholdWarningOnlyEnabled")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub threshold_warning_only_enabled: Option<bool>,
}

impl crate::Metadata<'static> for MaxPrefix {
    const JSON_SCHEMA: &'static str = "AddressPool.v1_2_1.json";
}