redfish-codegen 0.3.1

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

use crate::models;

/// This type specifies the details of the transport supported by the endpoint.  The properties that are present are dependent on the type of transport supported by the endpoint.
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]
#[derive(derivative::Derivative)]
#[derivative(Default)]
pub struct IPTransportDetails {
    #[serde(rename = "IPv4Address")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub ipv4_address: Option<models::ip_addresses::IPv4Address>,
    #[serde(rename = "IPv6Address")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub ipv6_address: Option<models::ip_addresses::IPv6Address>,
    /// The UDP or TCP port number used by the endpoint.
    #[serde(rename = "Port")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub port: Option<f64>,
    #[serde(rename = "TransportProtocol")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub transport_protocol: Option<models::protocol::Protocol>,
}

impl crate::Metadata<'static> for IPTransportDetails {
    const JSON_SCHEMA: &'static str = "Endpoint.v1_8_0.json";
}