nominal-api-conjure 0.1379.0

Conjure HTTP API bindings for the Nominal platform
Documentation
/// Compute resources granted to an extractor container. Every field is optional; an unset
/// field falls back to the deployment-wide default configured on combined-service.
#[derive(
    Debug,
    Clone,
    conjure_object::serde::Serialize,
    conjure_object::serde::Deserialize,
    PartialEq,
    Eq,
    PartialOrd,
    Ord,
    Hash,
    Copy
)]
#[serde(crate = "conjure_object::serde")]
#[conjure_object::private::staged_builder::staged_builder]
#[builder(crate = conjure_object::private::staged_builder, update, inline)]
pub struct ContainerResources {
    #[builder(default, into)]
    #[serde(rename = "cpuCores", skip_serializing_if = "Option::is_none", default)]
    cpu_cores: Option<i32>,
    #[builder(default, into)]
    #[serde(rename = "memoryGib", skip_serializing_if = "Option::is_none", default)]
    memory_gib: Option<i32>,
    #[builder(default, into)]
    #[serde(rename = "diskGib", skip_serializing_if = "Option::is_none", default)]
    disk_gib: Option<i32>,
}
impl ContainerResources {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new() -> Self {
        Self::builder().build()
    }
    /// CPU cores requested for the extractor container.
    #[inline]
    pub fn cpu_cores(&self) -> Option<i32> {
        self.cpu_cores.as_ref().map(|o| *o)
    }
    /// Memory in GiB, applied as both the request and the limit.
    #[inline]
    pub fn memory_gib(&self) -> Option<i32> {
        self.memory_gib.as_ref().map(|o| *o)
    }
    /// Size in GiB of each of the ephemeral input and output volumes.
    #[inline]
    pub fn disk_gib(&self) -> Option<i32> {
        self.disk_gib.as_ref().map(|o| *o)
    }
}