Skip to main content

nominal_api/conjure/objects/ingest/api/
video_file_ingest_details.rs

1#[derive(
2    Debug,
3    Clone,
4    conjure_object::serde::Serialize,
5    conjure_object::serde::Deserialize,
6    PartialEq,
7    Eq,
8    PartialOrd,
9    Ord,
10    Hash
11)]
12#[serde(crate = "conjure_object::serde")]
13#[conjure_object::private::staged_builder::staged_builder]
14#[builder(crate = conjure_object::private::staged_builder, update, inline)]
15pub struct VideoFileIngestDetails {
16    #[builder(default, into)]
17    #[serde(
18        rename = "fileDescription",
19        skip_serializing_if = "Option::is_none",
20        default
21    )]
22    file_description: Option<String>,
23    #[builder(default, into)]
24    #[serde(rename = "fileProperties", skip_serializing_if = "Option::is_none", default)]
25    file_properties: Option<
26        std::collections::BTreeMap<
27            super::super::super::api::PropertyName,
28            super::super::super::api::PropertyValue,
29        >,
30    >,
31    #[builder(default, into)]
32    #[serde(rename = "fileLabels", skip_serializing_if = "Option::is_none", default)]
33    file_labels: Option<std::collections::BTreeSet<super::super::super::api::Label>>,
34}
35impl VideoFileIngestDetails {
36    /// Constructs a new instance of the type.
37    #[inline]
38    pub fn new() -> Self {
39        Self::builder().build()
40    }
41    /// Description that is applied to the newly created video file.
42    /// If not provided, defaults to the description used to create the video.
43    #[inline]
44    pub fn file_description(&self) -> Option<&str> {
45        self.file_description.as_ref().map(|o| &**o)
46    }
47    /// Key-Value properties that are applied to the newly created video file.
48    #[deprecated(
49        note = "Field is ignored as video files do not have properties.\nWill be removed after 4/5/2025\n"
50    )]
51    #[inline]
52    pub fn file_properties(
53        &self,
54    ) -> Option<
55        &std::collections::BTreeMap<
56            super::super::super::api::PropertyName,
57            super::super::super::api::PropertyValue,
58        >,
59    > {
60        self.file_properties.as_ref().map(|o| &*o)
61    }
62    /// Labels that are applied to the newly created video file.
63    #[deprecated(
64        note = "Field is ignored as video files do not have labels.\nWill be removed after 4/5/2025\n"
65    )]
66    #[inline]
67    pub fn file_labels(
68        &self,
69    ) -> Option<&std::collections::BTreeSet<super::super::super::api::Label>> {
70        self.file_labels.as_ref().map(|o| &*o)
71    }
72}