Skip to main content

aws_sdk_appstream/operation/update_stack/
_update_stack_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 UpdateStackInput {
6    /// <p>The stack name to display.</p>
7    pub display_name: ::std::option::Option<::std::string::String>,
8    /// <p>The description to display.</p>
9    pub description: ::std::option::Option<::std::string::String>,
10    /// <p>The name of the stack.</p>
11    pub name: ::std::option::Option<::std::string::String>,
12    /// <p>The storage connectors to enable.</p>
13    pub storage_connectors: ::std::option::Option<::std::vec::Vec<crate::types::StorageConnector>>,
14    /// <p>Deletes the storage connectors currently enabled for the stack.</p>
15    #[deprecated]
16    pub delete_storage_connectors: ::std::option::Option<bool>,
17    /// <p>The URL that users are redirected to after their streaming session ends.</p>
18    pub redirect_url: ::std::option::Option<::std::string::String>,
19    /// <p>The URL that users are redirected to after they choose the Send Feedback link. If no URL is specified, no Send Feedback link is displayed.</p>
20    pub feedback_url: ::std::option::Option<::std::string::String>,
21    /// <p>The stack attributes to delete.</p>
22    pub attributes_to_delete: ::std::option::Option<::std::vec::Vec<crate::types::StackAttribute>>,
23    /// <p>The actions that are enabled or disabled for users during their streaming sessions. By default, these actions are enabled.</p>
24    pub user_settings: ::std::option::Option<::std::vec::Vec<crate::types::UserSetting>>,
25    /// <p>The persistent application settings for users of a stack. When these settings are enabled, changes that users make to applications and Windows settings are automatically saved after each session and applied to the next session.</p>
26    pub application_settings: ::std::option::Option<crate::types::ApplicationSettings>,
27    /// <p>The list of interface VPC endpoint (interface endpoint) objects. Users of the stack can connect to WorkSpaces Applications only through the specified endpoints.</p>
28    pub access_endpoints: ::std::option::Option<::std::vec::Vec<crate::types::AccessEndpoint>>,
29    /// <p>The domains where WorkSpaces Applications streaming sessions can be embedded in an iframe. You must approve the domains that you want to host embedded WorkSpaces Applications streaming sessions.</p>
30    pub embed_host_domains: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
31    /// <p>The streaming protocol you want your stack to prefer. This can be UDP or TCP. Currently, UDP is only supported in the Windows native client.</p>
32    pub streaming_experience_settings: ::std::option::Option<crate::types::StreamingExperienceSettings>,
33    /// <p>Configuration for bidirectional URL redirection between the streaming session and the local client. Use HostToClient to redirect URLs from the remote desktop to the local browser.</p>
34    pub content_redirection: ::std::option::Option<crate::types::ContentRedirection>,
35    /// <p>The configuration for agent access on the stack. Specify this to update agent access settings. To remove agent access, use AttributesToDelete with the AGENT_ACCESS_CONFIG value.</p>
36    pub agent_access_config: ::std::option::Option<crate::types::AgentAccessConfigForUpdate>,
37}
38impl UpdateStackInput {
39    /// <p>The stack name to display.</p>
40    pub fn display_name(&self) -> ::std::option::Option<&str> {
41        self.display_name.as_deref()
42    }
43    /// <p>The description to display.</p>
44    pub fn description(&self) -> ::std::option::Option<&str> {
45        self.description.as_deref()
46    }
47    /// <p>The name of the stack.</p>
48    pub fn name(&self) -> ::std::option::Option<&str> {
49        self.name.as_deref()
50    }
51    /// <p>The storage connectors to enable.</p>
52    ///
53    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.storage_connectors.is_none()`.
54    pub fn storage_connectors(&self) -> &[crate::types::StorageConnector] {
55        self.storage_connectors.as_deref().unwrap_or_default()
56    }
57    /// <p>Deletes the storage connectors currently enabled for the stack.</p>
58    #[deprecated]
59    pub fn delete_storage_connectors(&self) -> ::std::option::Option<bool> {
60        self.delete_storage_connectors
61    }
62    /// <p>The URL that users are redirected to after their streaming session ends.</p>
63    pub fn redirect_url(&self) -> ::std::option::Option<&str> {
64        self.redirect_url.as_deref()
65    }
66    /// <p>The URL that users are redirected to after they choose the Send Feedback link. If no URL is specified, no Send Feedback link is displayed.</p>
67    pub fn feedback_url(&self) -> ::std::option::Option<&str> {
68        self.feedback_url.as_deref()
69    }
70    /// <p>The stack attributes to delete.</p>
71    ///
72    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.attributes_to_delete.is_none()`.
73    pub fn attributes_to_delete(&self) -> &[crate::types::StackAttribute] {
74        self.attributes_to_delete.as_deref().unwrap_or_default()
75    }
76    /// <p>The actions that are enabled or disabled for users during their streaming sessions. By default, these actions are enabled.</p>
77    ///
78    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.user_settings.is_none()`.
79    pub fn user_settings(&self) -> &[crate::types::UserSetting] {
80        self.user_settings.as_deref().unwrap_or_default()
81    }
82    /// <p>The persistent application settings for users of a stack. When these settings are enabled, changes that users make to applications and Windows settings are automatically saved after each session and applied to the next session.</p>
83    pub fn application_settings(&self) -> ::std::option::Option<&crate::types::ApplicationSettings> {
84        self.application_settings.as_ref()
85    }
86    /// <p>The list of interface VPC endpoint (interface endpoint) objects. Users of the stack can connect to WorkSpaces Applications only through the specified endpoints.</p>
87    ///
88    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.access_endpoints.is_none()`.
89    pub fn access_endpoints(&self) -> &[crate::types::AccessEndpoint] {
90        self.access_endpoints.as_deref().unwrap_or_default()
91    }
92    /// <p>The domains where WorkSpaces Applications streaming sessions can be embedded in an iframe. You must approve the domains that you want to host embedded WorkSpaces Applications streaming sessions.</p>
93    ///
94    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.embed_host_domains.is_none()`.
95    pub fn embed_host_domains(&self) -> &[::std::string::String] {
96        self.embed_host_domains.as_deref().unwrap_or_default()
97    }
98    /// <p>The streaming protocol you want your stack to prefer. This can be UDP or TCP. Currently, UDP is only supported in the Windows native client.</p>
99    pub fn streaming_experience_settings(&self) -> ::std::option::Option<&crate::types::StreamingExperienceSettings> {
100        self.streaming_experience_settings.as_ref()
101    }
102    /// <p>Configuration for bidirectional URL redirection between the streaming session and the local client. Use HostToClient to redirect URLs from the remote desktop to the local browser.</p>
103    pub fn content_redirection(&self) -> ::std::option::Option<&crate::types::ContentRedirection> {
104        self.content_redirection.as_ref()
105    }
106    /// <p>The configuration for agent access on the stack. Specify this to update agent access settings. To remove agent access, use AttributesToDelete with the AGENT_ACCESS_CONFIG value.</p>
107    pub fn agent_access_config(&self) -> ::std::option::Option<&crate::types::AgentAccessConfigForUpdate> {
108        self.agent_access_config.as_ref()
109    }
110}
111impl UpdateStackInput {
112    /// Creates a new builder-style object to manufacture [`UpdateStackInput`](crate::operation::update_stack::UpdateStackInput).
113    pub fn builder() -> crate::operation::update_stack::builders::UpdateStackInputBuilder {
114        crate::operation::update_stack::builders::UpdateStackInputBuilder::default()
115    }
116}
117
118/// A builder for [`UpdateStackInput`](crate::operation::update_stack::UpdateStackInput).
119#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
120#[non_exhaustive]
121pub struct UpdateStackInputBuilder {
122    pub(crate) display_name: ::std::option::Option<::std::string::String>,
123    pub(crate) description: ::std::option::Option<::std::string::String>,
124    pub(crate) name: ::std::option::Option<::std::string::String>,
125    pub(crate) storage_connectors: ::std::option::Option<::std::vec::Vec<crate::types::StorageConnector>>,
126    pub(crate) delete_storage_connectors: ::std::option::Option<bool>,
127    pub(crate) redirect_url: ::std::option::Option<::std::string::String>,
128    pub(crate) feedback_url: ::std::option::Option<::std::string::String>,
129    pub(crate) attributes_to_delete: ::std::option::Option<::std::vec::Vec<crate::types::StackAttribute>>,
130    pub(crate) user_settings: ::std::option::Option<::std::vec::Vec<crate::types::UserSetting>>,
131    pub(crate) application_settings: ::std::option::Option<crate::types::ApplicationSettings>,
132    pub(crate) access_endpoints: ::std::option::Option<::std::vec::Vec<crate::types::AccessEndpoint>>,
133    pub(crate) embed_host_domains: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
134    pub(crate) streaming_experience_settings: ::std::option::Option<crate::types::StreamingExperienceSettings>,
135    pub(crate) content_redirection: ::std::option::Option<crate::types::ContentRedirection>,
136    pub(crate) agent_access_config: ::std::option::Option<crate::types::AgentAccessConfigForUpdate>,
137}
138impl UpdateStackInputBuilder {
139    /// <p>The stack name to display.</p>
140    pub fn display_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
141        self.display_name = ::std::option::Option::Some(input.into());
142        self
143    }
144    /// <p>The stack name to display.</p>
145    pub fn set_display_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
146        self.display_name = input;
147        self
148    }
149    /// <p>The stack name to display.</p>
150    pub fn get_display_name(&self) -> &::std::option::Option<::std::string::String> {
151        &self.display_name
152    }
153    /// <p>The description to display.</p>
154    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
155        self.description = ::std::option::Option::Some(input.into());
156        self
157    }
158    /// <p>The description to display.</p>
159    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
160        self.description = input;
161        self
162    }
163    /// <p>The description to display.</p>
164    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
165        &self.description
166    }
167    /// <p>The name of the stack.</p>
168    /// This field is required.
169    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
170        self.name = ::std::option::Option::Some(input.into());
171        self
172    }
173    /// <p>The name of the stack.</p>
174    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
175        self.name = input;
176        self
177    }
178    /// <p>The name of the stack.</p>
179    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
180        &self.name
181    }
182    /// Appends an item to `storage_connectors`.
183    ///
184    /// To override the contents of this collection use [`set_storage_connectors`](Self::set_storage_connectors).
185    ///
186    /// <p>The storage connectors to enable.</p>
187    pub fn storage_connectors(mut self, input: crate::types::StorageConnector) -> Self {
188        let mut v = self.storage_connectors.unwrap_or_default();
189        v.push(input);
190        self.storage_connectors = ::std::option::Option::Some(v);
191        self
192    }
193    /// <p>The storage connectors to enable.</p>
194    pub fn set_storage_connectors(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::StorageConnector>>) -> Self {
195        self.storage_connectors = input;
196        self
197    }
198    /// <p>The storage connectors to enable.</p>
199    pub fn get_storage_connectors(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::StorageConnector>> {
200        &self.storage_connectors
201    }
202    /// <p>Deletes the storage connectors currently enabled for the stack.</p>
203    #[deprecated]
204    pub fn delete_storage_connectors(mut self, input: bool) -> Self {
205        self.delete_storage_connectors = ::std::option::Option::Some(input);
206        self
207    }
208    /// <p>Deletes the storage connectors currently enabled for the stack.</p>
209    #[deprecated]
210    pub fn set_delete_storage_connectors(mut self, input: ::std::option::Option<bool>) -> Self {
211        self.delete_storage_connectors = input;
212        self
213    }
214    /// <p>Deletes the storage connectors currently enabled for the stack.</p>
215    #[deprecated]
216    pub fn get_delete_storage_connectors(&self) -> &::std::option::Option<bool> {
217        &self.delete_storage_connectors
218    }
219    /// <p>The URL that users are redirected to after their streaming session ends.</p>
220    pub fn redirect_url(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
221        self.redirect_url = ::std::option::Option::Some(input.into());
222        self
223    }
224    /// <p>The URL that users are redirected to after their streaming session ends.</p>
225    pub fn set_redirect_url(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
226        self.redirect_url = input;
227        self
228    }
229    /// <p>The URL that users are redirected to after their streaming session ends.</p>
230    pub fn get_redirect_url(&self) -> &::std::option::Option<::std::string::String> {
231        &self.redirect_url
232    }
233    /// <p>The URL that users are redirected to after they choose the Send Feedback link. If no URL is specified, no Send Feedback link is displayed.</p>
234    pub fn feedback_url(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
235        self.feedback_url = ::std::option::Option::Some(input.into());
236        self
237    }
238    /// <p>The URL that users are redirected to after they choose the Send Feedback link. If no URL is specified, no Send Feedback link is displayed.</p>
239    pub fn set_feedback_url(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
240        self.feedback_url = input;
241        self
242    }
243    /// <p>The URL that users are redirected to after they choose the Send Feedback link. If no URL is specified, no Send Feedback link is displayed.</p>
244    pub fn get_feedback_url(&self) -> &::std::option::Option<::std::string::String> {
245        &self.feedback_url
246    }
247    /// Appends an item to `attributes_to_delete`.
248    ///
249    /// To override the contents of this collection use [`set_attributes_to_delete`](Self::set_attributes_to_delete).
250    ///
251    /// <p>The stack attributes to delete.</p>
252    pub fn attributes_to_delete(mut self, input: crate::types::StackAttribute) -> Self {
253        let mut v = self.attributes_to_delete.unwrap_or_default();
254        v.push(input);
255        self.attributes_to_delete = ::std::option::Option::Some(v);
256        self
257    }
258    /// <p>The stack attributes to delete.</p>
259    pub fn set_attributes_to_delete(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::StackAttribute>>) -> Self {
260        self.attributes_to_delete = input;
261        self
262    }
263    /// <p>The stack attributes to delete.</p>
264    pub fn get_attributes_to_delete(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::StackAttribute>> {
265        &self.attributes_to_delete
266    }
267    /// Appends an item to `user_settings`.
268    ///
269    /// To override the contents of this collection use [`set_user_settings`](Self::set_user_settings).
270    ///
271    /// <p>The actions that are enabled or disabled for users during their streaming sessions. By default, these actions are enabled.</p>
272    pub fn user_settings(mut self, input: crate::types::UserSetting) -> Self {
273        let mut v = self.user_settings.unwrap_or_default();
274        v.push(input);
275        self.user_settings = ::std::option::Option::Some(v);
276        self
277    }
278    /// <p>The actions that are enabled or disabled for users during their streaming sessions. By default, these actions are enabled.</p>
279    pub fn set_user_settings(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::UserSetting>>) -> Self {
280        self.user_settings = input;
281        self
282    }
283    /// <p>The actions that are enabled or disabled for users during their streaming sessions. By default, these actions are enabled.</p>
284    pub fn get_user_settings(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::UserSetting>> {
285        &self.user_settings
286    }
287    /// <p>The persistent application settings for users of a stack. When these settings are enabled, changes that users make to applications and Windows settings are automatically saved after each session and applied to the next session.</p>
288    pub fn application_settings(mut self, input: crate::types::ApplicationSettings) -> Self {
289        self.application_settings = ::std::option::Option::Some(input);
290        self
291    }
292    /// <p>The persistent application settings for users of a stack. When these settings are enabled, changes that users make to applications and Windows settings are automatically saved after each session and applied to the next session.</p>
293    pub fn set_application_settings(mut self, input: ::std::option::Option<crate::types::ApplicationSettings>) -> Self {
294        self.application_settings = input;
295        self
296    }
297    /// <p>The persistent application settings for users of a stack. When these settings are enabled, changes that users make to applications and Windows settings are automatically saved after each session and applied to the next session.</p>
298    pub fn get_application_settings(&self) -> &::std::option::Option<crate::types::ApplicationSettings> {
299        &self.application_settings
300    }
301    /// Appends an item to `access_endpoints`.
302    ///
303    /// To override the contents of this collection use [`set_access_endpoints`](Self::set_access_endpoints).
304    ///
305    /// <p>The list of interface VPC endpoint (interface endpoint) objects. Users of the stack can connect to WorkSpaces Applications only through the specified endpoints.</p>
306    pub fn access_endpoints(mut self, input: crate::types::AccessEndpoint) -> Self {
307        let mut v = self.access_endpoints.unwrap_or_default();
308        v.push(input);
309        self.access_endpoints = ::std::option::Option::Some(v);
310        self
311    }
312    /// <p>The list of interface VPC endpoint (interface endpoint) objects. Users of the stack can connect to WorkSpaces Applications only through the specified endpoints.</p>
313    pub fn set_access_endpoints(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::AccessEndpoint>>) -> Self {
314        self.access_endpoints = input;
315        self
316    }
317    /// <p>The list of interface VPC endpoint (interface endpoint) objects. Users of the stack can connect to WorkSpaces Applications only through the specified endpoints.</p>
318    pub fn get_access_endpoints(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::AccessEndpoint>> {
319        &self.access_endpoints
320    }
321    /// Appends an item to `embed_host_domains`.
322    ///
323    /// To override the contents of this collection use [`set_embed_host_domains`](Self::set_embed_host_domains).
324    ///
325    /// <p>The domains where WorkSpaces Applications streaming sessions can be embedded in an iframe. You must approve the domains that you want to host embedded WorkSpaces Applications streaming sessions.</p>
326    pub fn embed_host_domains(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
327        let mut v = self.embed_host_domains.unwrap_or_default();
328        v.push(input.into());
329        self.embed_host_domains = ::std::option::Option::Some(v);
330        self
331    }
332    /// <p>The domains where WorkSpaces Applications streaming sessions can be embedded in an iframe. You must approve the domains that you want to host embedded WorkSpaces Applications streaming sessions.</p>
333    pub fn set_embed_host_domains(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
334        self.embed_host_domains = input;
335        self
336    }
337    /// <p>The domains where WorkSpaces Applications streaming sessions can be embedded in an iframe. You must approve the domains that you want to host embedded WorkSpaces Applications streaming sessions.</p>
338    pub fn get_embed_host_domains(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
339        &self.embed_host_domains
340    }
341    /// <p>The streaming protocol you want your stack to prefer. This can be UDP or TCP. Currently, UDP is only supported in the Windows native client.</p>
342    pub fn streaming_experience_settings(mut self, input: crate::types::StreamingExperienceSettings) -> Self {
343        self.streaming_experience_settings = ::std::option::Option::Some(input);
344        self
345    }
346    /// <p>The streaming protocol you want your stack to prefer. This can be UDP or TCP. Currently, UDP is only supported in the Windows native client.</p>
347    pub fn set_streaming_experience_settings(mut self, input: ::std::option::Option<crate::types::StreamingExperienceSettings>) -> Self {
348        self.streaming_experience_settings = input;
349        self
350    }
351    /// <p>The streaming protocol you want your stack to prefer. This can be UDP or TCP. Currently, UDP is only supported in the Windows native client.</p>
352    pub fn get_streaming_experience_settings(&self) -> &::std::option::Option<crate::types::StreamingExperienceSettings> {
353        &self.streaming_experience_settings
354    }
355    /// <p>Configuration for bidirectional URL redirection between the streaming session and the local client. Use HostToClient to redirect URLs from the remote desktop to the local browser.</p>
356    pub fn content_redirection(mut self, input: crate::types::ContentRedirection) -> Self {
357        self.content_redirection = ::std::option::Option::Some(input);
358        self
359    }
360    /// <p>Configuration for bidirectional URL redirection between the streaming session and the local client. Use HostToClient to redirect URLs from the remote desktop to the local browser.</p>
361    pub fn set_content_redirection(mut self, input: ::std::option::Option<crate::types::ContentRedirection>) -> Self {
362        self.content_redirection = input;
363        self
364    }
365    /// <p>Configuration for bidirectional URL redirection between the streaming session and the local client. Use HostToClient to redirect URLs from the remote desktop to the local browser.</p>
366    pub fn get_content_redirection(&self) -> &::std::option::Option<crate::types::ContentRedirection> {
367        &self.content_redirection
368    }
369    /// <p>The configuration for agent access on the stack. Specify this to update agent access settings. To remove agent access, use AttributesToDelete with the AGENT_ACCESS_CONFIG value.</p>
370    pub fn agent_access_config(mut self, input: crate::types::AgentAccessConfigForUpdate) -> Self {
371        self.agent_access_config = ::std::option::Option::Some(input);
372        self
373    }
374    /// <p>The configuration for agent access on the stack. Specify this to update agent access settings. To remove agent access, use AttributesToDelete with the AGENT_ACCESS_CONFIG value.</p>
375    pub fn set_agent_access_config(mut self, input: ::std::option::Option<crate::types::AgentAccessConfigForUpdate>) -> Self {
376        self.agent_access_config = input;
377        self
378    }
379    /// <p>The configuration for agent access on the stack. Specify this to update agent access settings. To remove agent access, use AttributesToDelete with the AGENT_ACCESS_CONFIG value.</p>
380    pub fn get_agent_access_config(&self) -> &::std::option::Option<crate::types::AgentAccessConfigForUpdate> {
381        &self.agent_access_config
382    }
383    /// Consumes the builder and constructs a [`UpdateStackInput`](crate::operation::update_stack::UpdateStackInput).
384    pub fn build(self) -> ::std::result::Result<crate::operation::update_stack::UpdateStackInput, ::aws_smithy_types::error::operation::BuildError> {
385        ::std::result::Result::Ok(crate::operation::update_stack::UpdateStackInput {
386            display_name: self.display_name,
387            description: self.description,
388            name: self.name,
389            storage_connectors: self.storage_connectors,
390            delete_storage_connectors: self.delete_storage_connectors,
391            redirect_url: self.redirect_url,
392            feedback_url: self.feedback_url,
393            attributes_to_delete: self.attributes_to_delete,
394            user_settings: self.user_settings,
395            application_settings: self.application_settings,
396            access_endpoints: self.access_endpoints,
397            embed_host_domains: self.embed_host_domains,
398            streaming_experience_settings: self.streaming_experience_settings,
399            content_redirection: self.content_redirection,
400            agent_access_config: self.agent_access_config,
401        })
402    }
403}