nominal_api/conjure/errors/module/
invalid_function_names.rs1#[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 InvalidFunctionNames {
18 #[builder(default, set(item(type = String, into)))]
19 #[serde(
20 rename = "functionNames",
21 skip_serializing_if = "std::collections::BTreeSet::is_empty",
22 default
23 )]
24 function_names: std::collections::BTreeSet<String>,
25}
26impl InvalidFunctionNames {
27 #[inline]
29 pub fn new() -> Self {
30 Self::builder().build()
31 }
32 #[inline]
33 pub fn function_names(&self) -> &std::collections::BTreeSet<String> {
34 &self.function_names
35 }
36}
37impl conjure_error::ErrorType for InvalidFunctionNames {
38 #[inline]
39 fn code() -> conjure_error::ErrorCode {
40 conjure_error::ErrorCode::InvalidArgument
41 }
42 #[inline]
43 fn name() -> &'static str {
44 "Module:InvalidFunctionNames"
45 }
46 #[inline]
47 fn safe_args() -> &'static [&'static str] {
48 &[]
49 }
50}