Skip to main content

nominal_api/conjure/objects/scout/checks/api/
submit_jobs_request.rs

1#[derive(
2    Debug,
3    Clone,
4    conjure_object::serde::Serialize,
5    conjure_object::serde::Deserialize,
6    conjure_object::private::DeriveWith
7)]
8#[serde(crate = "conjure_object::serde")]
9#[derive_with(PartialEq, Eq, PartialOrd, Ord, Hash)]
10#[conjure_object::private::staged_builder::staged_builder]
11#[builder(crate = conjure_object::private::staged_builder, update, inline)]
12pub struct SubmitJobsRequest {
13    #[builder(default, set(item(type = super::JobSpec)))]
14    #[serde(
15        rename = "jobsToExecute",
16        skip_serializing_if = "std::collections::BTreeSet::is_empty",
17        default
18    )]
19    jobs_to_execute: std::collections::BTreeSet<super::JobSpec>,
20}
21impl SubmitJobsRequest {
22    /// Constructs a new instance of the type.
23    #[inline]
24    pub fn new() -> Self {
25        Self::builder().build()
26    }
27    #[inline]
28    pub fn jobs_to_execute(&self) -> &std::collections::BTreeSet<super::JobSpec> {
29        &self.jobs_to_execute
30    }
31}