nominal-api 0.1239.0

API bindings for the Nominal platform
Documentation
/// Describes a single output file from a containerized extractor.
/// This is written by the container in manifest.json.
#[derive(
    Debug,
    Clone,
    conjure_object::serde::Serialize,
    conjure_object::serde::Deserialize,
    PartialEq,
    Eq,
    PartialOrd,
    Ord,
    Hash
)]
#[serde(crate = "conjure_object::serde")]
#[conjure_object::private::staged_builder::staged_builder]
#[builder(crate = conjure_object::private::staged_builder, update, inline)]
pub struct ManifestOutput {
    #[serde(rename = "ingestType")]
    ingest_type: super::ManifestIngestType,
    #[builder(into)]
    #[serde(rename = "relativePath")]
    relative_path: String,
    #[builder(default, map(key(type = String, into), value(type = String, into)))]
    #[serde(
        rename = "tagColumns",
        skip_serializing_if = "std::collections::BTreeMap::is_empty",
        default
    )]
    tag_columns: std::collections::BTreeMap<String, String>,
    #[builder(default, into)]
    #[serde(rename = "channelPrefix", skip_serializing_if = "Option::is_none", default)]
    channel_prefix: Option<String>,
}
impl ManifestOutput {
    /// Constructs a new instance of the type.
    #[inline]
    pub fn new(
        ingest_type: super::ManifestIngestType,
        relative_path: impl Into<String>,
    ) -> Self {
        Self::builder().ingest_type(ingest_type).relative_path(relative_path).build()
    }
    /// The type of ingestion for this output file
    #[inline]
    pub fn ingest_type(&self) -> &super::ManifestIngestType {
        &self.ingest_type
    }
    /// Relative path to the output file within OUTPUT_DIR.
    /// Example: "telemetry.csv" or "data/sensor_readings.parquet"
    #[inline]
    pub fn relative_path(&self) -> &str {
        &*self.relative_path
    }
    /// Optional mapping of tag names to column names for CSV/Parquet ingestion.
    /// Example: {"vehicle_id": "veh_id", "mission_id": "msn_id"}
    #[inline]
    pub fn tag_columns(&self) -> &std::collections::BTreeMap<String, String> {
        &self.tag_columns
    }
    /// Optional prefix to prepend to channel names during ingestion.
    /// Example: "telemetry/" would create channels like "telemetry/speed", "telemetry/altitude"
    #[inline]
    pub fn channel_prefix(&self) -> Option<&str> {
        self.channel_prefix.as_ref().map(|o| &**o)
    }
}