aws_sdk_finspace/operation/update_environment/
_update_environment_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct UpdateEnvironmentInput {
6    /// <p>The identifier of the FinSpace environment.</p>
7    pub environment_id: ::std::option::Option<::std::string::String>,
8    /// <p>The name of the environment.</p>
9    pub name: ::std::option::Option<::std::string::String>,
10    /// <p>The description of the environment.</p>
11    pub description: ::std::option::Option<::std::string::String>,
12    /// <p>Authentication mode for the environment.</p>
13    /// <ul>
14    /// <li>
15    /// <p><code>FEDERATED</code> - Users access FinSpace through Single Sign On (SSO) via your Identity provider.</p></li>
16    /// <li>
17    /// <p><code>LOCAL</code> - Users access FinSpace via email and password managed within the FinSpace environment.</p></li>
18    /// </ul>
19    pub federation_mode: ::std::option::Option<crate::types::FederationMode>,
20    /// <p>Configuration information when authentication mode is FEDERATED.</p>
21    pub federation_parameters: ::std::option::Option<crate::types::FederationParameters>,
22}
23impl UpdateEnvironmentInput {
24    /// <p>The identifier of the FinSpace environment.</p>
25    pub fn environment_id(&self) -> ::std::option::Option<&str> {
26        self.environment_id.as_deref()
27    }
28    /// <p>The name of the environment.</p>
29    pub fn name(&self) -> ::std::option::Option<&str> {
30        self.name.as_deref()
31    }
32    /// <p>The description of the environment.</p>
33    pub fn description(&self) -> ::std::option::Option<&str> {
34        self.description.as_deref()
35    }
36    /// <p>Authentication mode for the environment.</p>
37    /// <ul>
38    /// <li>
39    /// <p><code>FEDERATED</code> - Users access FinSpace through Single Sign On (SSO) via your Identity provider.</p></li>
40    /// <li>
41    /// <p><code>LOCAL</code> - Users access FinSpace via email and password managed within the FinSpace environment.</p></li>
42    /// </ul>
43    pub fn federation_mode(&self) -> ::std::option::Option<&crate::types::FederationMode> {
44        self.federation_mode.as_ref()
45    }
46    /// <p>Configuration information when authentication mode is FEDERATED.</p>
47    pub fn federation_parameters(&self) -> ::std::option::Option<&crate::types::FederationParameters> {
48        self.federation_parameters.as_ref()
49    }
50}
51impl UpdateEnvironmentInput {
52    /// Creates a new builder-style object to manufacture [`UpdateEnvironmentInput`](crate::operation::update_environment::UpdateEnvironmentInput).
53    pub fn builder() -> crate::operation::update_environment::builders::UpdateEnvironmentInputBuilder {
54        crate::operation::update_environment::builders::UpdateEnvironmentInputBuilder::default()
55    }
56}
57
58/// A builder for [`UpdateEnvironmentInput`](crate::operation::update_environment::UpdateEnvironmentInput).
59#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
60#[non_exhaustive]
61pub struct UpdateEnvironmentInputBuilder {
62    pub(crate) environment_id: ::std::option::Option<::std::string::String>,
63    pub(crate) name: ::std::option::Option<::std::string::String>,
64    pub(crate) description: ::std::option::Option<::std::string::String>,
65    pub(crate) federation_mode: ::std::option::Option<crate::types::FederationMode>,
66    pub(crate) federation_parameters: ::std::option::Option<crate::types::FederationParameters>,
67}
68impl UpdateEnvironmentInputBuilder {
69    /// <p>The identifier of the FinSpace environment.</p>
70    /// This field is required.
71    pub fn environment_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
72        self.environment_id = ::std::option::Option::Some(input.into());
73        self
74    }
75    /// <p>The identifier of the FinSpace environment.</p>
76    pub fn set_environment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
77        self.environment_id = input;
78        self
79    }
80    /// <p>The identifier of the FinSpace environment.</p>
81    pub fn get_environment_id(&self) -> &::std::option::Option<::std::string::String> {
82        &self.environment_id
83    }
84    /// <p>The name of the environment.</p>
85    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
86        self.name = ::std::option::Option::Some(input.into());
87        self
88    }
89    /// <p>The name of the environment.</p>
90    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
91        self.name = input;
92        self
93    }
94    /// <p>The name of the environment.</p>
95    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
96        &self.name
97    }
98    /// <p>The description of the environment.</p>
99    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
100        self.description = ::std::option::Option::Some(input.into());
101        self
102    }
103    /// <p>The description of the environment.</p>
104    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
105        self.description = input;
106        self
107    }
108    /// <p>The description of the environment.</p>
109    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
110        &self.description
111    }
112    /// <p>Authentication mode for the environment.</p>
113    /// <ul>
114    /// <li>
115    /// <p><code>FEDERATED</code> - Users access FinSpace through Single Sign On (SSO) via your Identity provider.</p></li>
116    /// <li>
117    /// <p><code>LOCAL</code> - Users access FinSpace via email and password managed within the FinSpace environment.</p></li>
118    /// </ul>
119    pub fn federation_mode(mut self, input: crate::types::FederationMode) -> Self {
120        self.federation_mode = ::std::option::Option::Some(input);
121        self
122    }
123    /// <p>Authentication mode for the environment.</p>
124    /// <ul>
125    /// <li>
126    /// <p><code>FEDERATED</code> - Users access FinSpace through Single Sign On (SSO) via your Identity provider.</p></li>
127    /// <li>
128    /// <p><code>LOCAL</code> - Users access FinSpace via email and password managed within the FinSpace environment.</p></li>
129    /// </ul>
130    pub fn set_federation_mode(mut self, input: ::std::option::Option<crate::types::FederationMode>) -> Self {
131        self.federation_mode = input;
132        self
133    }
134    /// <p>Authentication mode for the environment.</p>
135    /// <ul>
136    /// <li>
137    /// <p><code>FEDERATED</code> - Users access FinSpace through Single Sign On (SSO) via your Identity provider.</p></li>
138    /// <li>
139    /// <p><code>LOCAL</code> - Users access FinSpace via email and password managed within the FinSpace environment.</p></li>
140    /// </ul>
141    pub fn get_federation_mode(&self) -> &::std::option::Option<crate::types::FederationMode> {
142        &self.federation_mode
143    }
144    /// <p>Configuration information when authentication mode is FEDERATED.</p>
145    pub fn federation_parameters(mut self, input: crate::types::FederationParameters) -> Self {
146        self.federation_parameters = ::std::option::Option::Some(input);
147        self
148    }
149    /// <p>Configuration information when authentication mode is FEDERATED.</p>
150    pub fn set_federation_parameters(mut self, input: ::std::option::Option<crate::types::FederationParameters>) -> Self {
151        self.federation_parameters = input;
152        self
153    }
154    /// <p>Configuration information when authentication mode is FEDERATED.</p>
155    pub fn get_federation_parameters(&self) -> &::std::option::Option<crate::types::FederationParameters> {
156        &self.federation_parameters
157    }
158    /// Consumes the builder and constructs a [`UpdateEnvironmentInput`](crate::operation::update_environment::UpdateEnvironmentInput).
159    pub fn build(
160        self,
161    ) -> ::std::result::Result<crate::operation::update_environment::UpdateEnvironmentInput, ::aws_smithy_types::error::operation::BuildError> {
162        ::std::result::Result::Ok(crate::operation::update_environment::UpdateEnvironmentInput {
163            environment_id: self.environment_id,
164            name: self.name,
165            description: self.description,
166            federation_mode: self.federation_mode,
167            federation_parameters: self.federation_parameters,
168        })
169    }
170}