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 chassis in which this resource block is contained.
    #[serde(rename = "Chassis")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub chassis: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Chassis@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub chassis_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the computer systems that are composed from this resource block.
    #[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>,
    /// An array of links to resource blocks that depend on this resource block.
    #[serde(rename = "ConsumingResourceBlocks")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub consuming_resource_blocks: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "ConsumingResourceBlocks@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub consuming_resource_blocks_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 resource blocks that this resource block depends on.
    #[serde(rename = "SupplyingResourceBlocks")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub supplying_resource_blocks: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "SupplyingResourceBlocks@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub supplying_resource_blocks_odata_count: Option<models::odata_v4::Count>,
    /// An array of links to the zones in which this resource block is bound.
    #[serde(rename = "Zones")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub zones: Option<Vec<models::odata_v4::IdRef>>,
    #[serde(rename = "Zones@odata.count")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub zones_odata_count: Option<models::odata_v4::Count>,
}

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