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;

/// Represents a remote resource that is connected to the network accessible to this endpoint.
#[derive(Clone, Debug, serde::Deserialize, serde::Serialize)]
#[derive(derivative::Derivative)]
#[derivative(Default)]
pub struct ConnectedEntity {
    #[serde(rename = "EntityLink")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub entity_link: Option<models::odata_v4::IdRef>,
    #[serde(rename = "EntityPciId")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub entity_pci_id: Option<models::endpoint::v1_8_0::PciId>,
    #[serde(rename = "EntityRole")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub entity_role: Option<models::endpoint::v1_8_0::EntityRole>,
    #[serde(rename = "EntityType")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub entity_type: Option<models::endpoint::v1_8_0::EntityType>,
    #[serde(rename = "GenZ")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub gen_z: Option<models::endpoint::v1_8_0::GenZ>,
    /// Identifiers for the remote entity.
    #[serde(rename = "Identifiers")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub identifiers: Option<Vec<models::resource::Identifier>>,
    #[serde(rename = "Oem")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub oem: Option<models::resource::Oem>,
    /// The Class Code, Subclass, and Programming Interface code of this PCIe function.
    #[serde(rename = "PciClassCode")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub pci_class_code: Option<String>,
    /// The PCI ID of the connected entity.
    #[serde(rename = "PciFunctionNumber")]
    #[serde(default, skip_serializing_if = "Option::is_none")]
    pub pci_function_number: Option<i64>,
}

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