nominal_api/conjure/objects/secrets/api/
update_secret_request.rs1#[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 UpdateSecretRequest {
16 #[builder(default, into)]
17 #[serde(rename = "name", skip_serializing_if = "Option::is_none", default)]
18 name: Option<String>,
19 #[builder(default, into)]
20 #[serde(rename = "description", skip_serializing_if = "Option::is_none", default)]
21 description: Option<String>,
22 #[builder(default, into)]
23 #[serde(rename = "properties", skip_serializing_if = "Option::is_none", default)]
24 properties: Option<std::collections::BTreeMap<String, String>>,
25 #[builder(default, into)]
26 #[serde(rename = "labels", skip_serializing_if = "Option::is_none", default)]
27 labels: Option<std::collections::BTreeSet<String>>,
28 #[builder(default, into)]
29 #[serde(rename = "decryptedValue", skip_serializing_if = "Option::is_none", default)]
30 decrypted_value: Option<String>,
31}
32impl UpdateSecretRequest {
33 #[inline]
35 pub fn new() -> Self {
36 Self::builder().build()
37 }
38 #[inline]
39 pub fn name(&self) -> Option<&str> {
40 self.name.as_ref().map(|o| &**o)
41 }
42 #[inline]
43 pub fn description(&self) -> Option<&str> {
44 self.description.as_ref().map(|o| &**o)
45 }
46 #[inline]
47 pub fn properties(&self) -> Option<&std::collections::BTreeMap<String, String>> {
48 self.properties.as_ref().map(|o| &*o)
49 }
50 #[inline]
51 pub fn labels(&self) -> Option<&std::collections::BTreeSet<String>> {
52 self.labels.as_ref().map(|o| &*o)
53 }
54 #[inline]
55 pub fn decrypted_value(&self) -> Option<&str> {
56 self.decrypted_value.as_ref().map(|o| &**o)
57 }
58}