aws_sdk_elasticbeanstalk/types/
_configuration_option_setting.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>A specification identifying an individual configuration option along with its current value. For a list of possible namespaces and option values, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/command-options.html">Option Values</a> in the <i>AWS Elastic Beanstalk Developer Guide</i>.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct ConfigurationOptionSetting {
7    /// <p>A unique resource name for the option setting. Use it for a time–based scaling configuration option.</p>
8    pub resource_name: ::std::option::Option<::std::string::String>,
9    /// <p>A unique namespace that identifies the option's associated AWS resource.</p>
10    pub namespace: ::std::option::Option<::std::string::String>,
11    /// <p>The name of the configuration option.</p>
12    pub option_name: ::std::option::Option<::std::string::String>,
13    /// <p>The current value for the configuration option.</p>
14    pub value: ::std::option::Option<::std::string::String>,
15}
16impl ConfigurationOptionSetting {
17    /// <p>A unique resource name for the option setting. Use it for a time–based scaling configuration option.</p>
18    pub fn resource_name(&self) -> ::std::option::Option<&str> {
19        self.resource_name.as_deref()
20    }
21    /// <p>A unique namespace that identifies the option's associated AWS resource.</p>
22    pub fn namespace(&self) -> ::std::option::Option<&str> {
23        self.namespace.as_deref()
24    }
25    /// <p>The name of the configuration option.</p>
26    pub fn option_name(&self) -> ::std::option::Option<&str> {
27        self.option_name.as_deref()
28    }
29    /// <p>The current value for the configuration option.</p>
30    pub fn value(&self) -> ::std::option::Option<&str> {
31        self.value.as_deref()
32    }
33}
34impl ConfigurationOptionSetting {
35    /// Creates a new builder-style object to manufacture [`ConfigurationOptionSetting`](crate::types::ConfigurationOptionSetting).
36    pub fn builder() -> crate::types::builders::ConfigurationOptionSettingBuilder {
37        crate::types::builders::ConfigurationOptionSettingBuilder::default()
38    }
39}
40
41/// A builder for [`ConfigurationOptionSetting`](crate::types::ConfigurationOptionSetting).
42#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
43#[non_exhaustive]
44pub struct ConfigurationOptionSettingBuilder {
45    pub(crate) resource_name: ::std::option::Option<::std::string::String>,
46    pub(crate) namespace: ::std::option::Option<::std::string::String>,
47    pub(crate) option_name: ::std::option::Option<::std::string::String>,
48    pub(crate) value: ::std::option::Option<::std::string::String>,
49}
50impl ConfigurationOptionSettingBuilder {
51    /// <p>A unique resource name for the option setting. Use it for a time–based scaling configuration option.</p>
52    pub fn resource_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53        self.resource_name = ::std::option::Option::Some(input.into());
54        self
55    }
56    /// <p>A unique resource name for the option setting. Use it for a time–based scaling configuration option.</p>
57    pub fn set_resource_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58        self.resource_name = input;
59        self
60    }
61    /// <p>A unique resource name for the option setting. Use it for a time–based scaling configuration option.</p>
62    pub fn get_resource_name(&self) -> &::std::option::Option<::std::string::String> {
63        &self.resource_name
64    }
65    /// <p>A unique namespace that identifies the option's associated AWS resource.</p>
66    pub fn namespace(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
67        self.namespace = ::std::option::Option::Some(input.into());
68        self
69    }
70    /// <p>A unique namespace that identifies the option's associated AWS resource.</p>
71    pub fn set_namespace(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
72        self.namespace = input;
73        self
74    }
75    /// <p>A unique namespace that identifies the option's associated AWS resource.</p>
76    pub fn get_namespace(&self) -> &::std::option::Option<::std::string::String> {
77        &self.namespace
78    }
79    /// <p>The name of the configuration option.</p>
80    pub fn option_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
81        self.option_name = ::std::option::Option::Some(input.into());
82        self
83    }
84    /// <p>The name of the configuration option.</p>
85    pub fn set_option_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
86        self.option_name = input;
87        self
88    }
89    /// <p>The name of the configuration option.</p>
90    pub fn get_option_name(&self) -> &::std::option::Option<::std::string::String> {
91        &self.option_name
92    }
93    /// <p>The current value for the configuration option.</p>
94    pub fn value(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
95        self.value = ::std::option::Option::Some(input.into());
96        self
97    }
98    /// <p>The current value for the configuration option.</p>
99    pub fn set_value(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
100        self.value = input;
101        self
102    }
103    /// <p>The current value for the configuration option.</p>
104    pub fn get_value(&self) -> &::std::option::Option<::std::string::String> {
105        &self.value
106    }
107    /// Consumes the builder and constructs a [`ConfigurationOptionSetting`](crate::types::ConfigurationOptionSetting).
108    pub fn build(self) -> crate::types::ConfigurationOptionSetting {
109        crate::types::ConfigurationOptionSetting {
110            resource_name: self.resource_name,
111            namespace: self.namespace,
112            option_name: self.option_name,
113            value: self.value,
114        }
115    }
116}