Skip to main content

nominal_api/conjure/errors/ingest/api/
reingest_too_many_files.rs

1/// The number of files to reingest is too large.
2#[derive(
3    Debug,
4    Clone,
5    conjure_object::serde::Serialize,
6    conjure_object::serde::Deserialize,
7    PartialEq,
8    Eq,
9    PartialOrd,
10    Ord,
11    Hash,
12    Copy
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 ReingestTooManyFiles {
18    #[serde(rename = "maxFiles")]
19    max_files: i32,
20}
21impl ReingestTooManyFiles {
22    /// Constructs a new instance of the type.
23    #[inline]
24    pub fn new(max_files: i32) -> Self {
25        Self::builder().max_files(max_files).build()
26    }
27    #[inline]
28    pub fn max_files(&self) -> i32 {
29        self.max_files
30    }
31}
32impl conjure_error::ErrorType for ReingestTooManyFiles {
33    #[inline]
34    fn code() -> conjure_error::ErrorCode {
35        conjure_error::ErrorCode::InvalidArgument
36    }
37    #[inline]
38    fn name() -> &'static str {
39        "IngestService:ReingestTooManyFiles"
40    }
41    #[inline]
42    fn safe_args() -> &'static [&'static str] {
43        &["maxFiles"]
44    }
45}