Skip to main content

nominal_api/conjure/objects/scout/compute/api/
run.rs

1/// Run reference for `CombineRunsFrame`. The `rid` field accepts either a literal run RID or a
2/// `StringConstant` reference resolved from `Context`.
3#[derive(
4    Debug,
5    Clone,
6    conjure_object::serde::Serialize,
7    conjure_object::serde::Deserialize,
8    PartialEq,
9    Eq,
10    PartialOrd,
11    Ord,
12    Hash
13)]
14#[serde(crate = "conjure_object::serde")]
15#[conjure_object::private::staged_builder::staged_builder]
16#[builder(crate = conjure_object::private::staged_builder, update, inline)]
17pub struct Run {
18    #[builder(custom(type = super::StringConstant, convert = Box::new))]
19    #[serde(rename = "rid")]
20    rid: Box<super::StringConstant>,
21}
22impl Run {
23    /// Constructs a new instance of the type.
24    #[inline]
25    pub fn new(rid: super::StringConstant) -> Self {
26        Self::builder().rid(rid).build()
27    }
28    /// Resource identifier of a run
29    #[inline]
30    pub fn rid(&self) -> &super::StringConstant {
31        &*self.rid
32    }
33}