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;

/// Properties that describe a PCIe interface.
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]
#[derive(derivative::Derivative)]
#[derivative(Default)]
pub struct PCIeInterface {
    /// The number of PCIe lanes in use by this device.
    #[serde(rename = "LanesInUse")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub lanes_in_use: Option<i64>,
    /// The number of PCIe lanes supported by this device.
    #[serde(rename = "MaxLanes")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub max_lanes: Option<i64>,
    #[serde(rename = "MaxPCIeType")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub max_pcie_type: Option<models::pcie_device::PCIeTypes>,
    #[serde(rename = "Oem")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub oem: Option<models::resource::Oem>,
    #[serde(rename = "PCIeType")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub pcie_type: Option<models::pcie_device::PCIeTypes>,
}

impl crate::Metadata<'static> for PCIeInterface {
    const JSON_SCHEMA: &'static str = "PCIeDevice.v1_3_3.json";
}