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;

/// The links to other resources that are related to this resource.
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]
#[derive(derivative::Derivative)]
#[derivative(Default)]
pub struct Links {
    /// An array of links to the cables connected to this chassis.
    #[serde(rename = "Cables")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cables: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Cables@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cables_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the computer systems that this chassis directly and wholly contains.
    #[serde(rename = "ComputerSystems")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub computer_systems: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "ComputerSystems@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub computer_systems_odata_count: Option<models::odata_v4::Count>,
    #[serde(rename = "ContainedBy")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub contained_by: Option<models::odata_v4::IdRef>,
    /// An array of links to any other chassis that this chassis has in it.
    #[serde(rename = "Contains")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub contains: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Contains@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub contains_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to resources or objects that cool this chassis.  Normally, the link is for either a chassis or a specific set of fans.
    #[serde(rename = "CooledBy")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cooled_by: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "CooledBy@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub cooled_by_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the drives located in this chassis.
    #[serde(rename = "Drives")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub drives: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Drives@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub drives_odata_count: Option<models::odata_v4::Count>,
    #[serde(rename = "Facility")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub facility: Option<models::odata_v4::IdRef>,
    /// An array of links to the fans that cool this chassis.
    #[serde(rename = "Fans")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub fans: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Fans@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub fans_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the managers responsible for managing this chassis.
    #[serde(rename = "ManagedBy")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub managed_by: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "ManagedBy@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub managed_by_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the managers located in this chassis.
    #[serde(rename = "ManagersInChassis")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub managers_in_chassis: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "ManagersInChassis@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub managers_in_chassis_odata_count: Option<models::odata_v4::Count>,
    #[serde(rename = "Oem")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub oem: Option<models::resource::Oem>,
    /// An array of links to the PCIe devices located in this chassis.
    #[serde(rename = "PCIeDevices")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub pcie_devices: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "PCIeDevices@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub pcie_devices_odata_count: Option<models::odata_v4::Count>,
    #[serde(rename = "PowerDistribution")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub power_distribution: Option<models::odata_v4::IdRef>,
    /// An array of links to the outlets that provide power to this chassis.
    #[serde(rename = "PowerOutlets")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub power_outlets: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "PowerOutlets@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub power_outlets_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the power supplies that provide power to this chassis.
    #[serde(rename = "PowerSupplies")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub power_supplies: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "PowerSupplies@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub power_supplies_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to resources or objects that power this chassis.  Normally, the link is for either a chassis or a specific set of power supplies.
    #[serde(rename = "PoweredBy")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub powered_by: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "PoweredBy@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub powered_by_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the processors located in this chassis.
    #[serde(rename = "Processors")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub processors: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Processors@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub processors_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the resource blocks located in this chassis.
    #[serde(rename = "ResourceBlocks")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub resource_blocks: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "ResourceBlocks@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub resource_blocks_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the storage subsystems connected to or inside this chassis.
    #[serde(rename = "Storage")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub storage: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Storage@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub storage_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the switches located in this chassis.
    #[serde(rename = "Switches")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub switches: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Switches@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub switches_odata_count: Option<models::odata_v4::Count>,
}

impl crate::Metadata<'static> for Links {
    const JSON_SCHEMA: &'static str = "Chassis.v1_22_0.json";
}