aws_sdk_appstream/operation/create_fleet/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::create_fleet::_create_fleet_output::CreateFleetOutputBuilder;
3
4pub use crate::operation::create_fleet::_create_fleet_input::CreateFleetInputBuilder;
5
6impl crate::operation::create_fleet::builders::CreateFleetInputBuilder {
7    /// Sends a request with this input using the given client.
8    pub async fn send_with(
9        self,
10        client: &crate::Client,
11    ) -> ::std::result::Result<
12        crate::operation::create_fleet::CreateFleetOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::create_fleet::CreateFleetError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.create_fleet();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `CreateFleet`.
24///
25/// <p>Creates a fleet. A fleet consists of streaming instances that your users access for their applications and desktops.</p>
26#[derive(::std::clone::Clone, ::std::fmt::Debug)]
27pub struct CreateFleetFluentBuilder {
28    handle: ::std::sync::Arc<crate::client::Handle>,
29    inner: crate::operation::create_fleet::builders::CreateFleetInputBuilder,
30    config_override: ::std::option::Option<crate::config::Builder>,
31}
32impl
33    crate::client::customize::internal::CustomizableSend<
34        crate::operation::create_fleet::CreateFleetOutput,
35        crate::operation::create_fleet::CreateFleetError,
36    > for CreateFleetFluentBuilder
37{
38    fn send(
39        self,
40        config_override: crate::config::Builder,
41    ) -> crate::client::customize::internal::BoxFuture<
42        crate::client::customize::internal::SendResult<
43            crate::operation::create_fleet::CreateFleetOutput,
44            crate::operation::create_fleet::CreateFleetError,
45        >,
46    > {
47        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
48    }
49}
50impl CreateFleetFluentBuilder {
51    /// Creates a new `CreateFleetFluentBuilder`.
52    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
53        Self {
54            handle,
55            inner: ::std::default::Default::default(),
56            config_override: ::std::option::Option::None,
57        }
58    }
59    /// Access the CreateFleet as a reference.
60    pub fn as_input(&self) -> &crate::operation::create_fleet::builders::CreateFleetInputBuilder {
61        &self.inner
62    }
63    /// Sends the request and returns the response.
64    ///
65    /// If an error occurs, an `SdkError` will be returned with additional details that
66    /// can be matched against.
67    ///
68    /// By default, any retryable failures will be retried twice. Retry behavior
69    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
70    /// set when configuring the client.
71    pub async fn send(
72        self,
73    ) -> ::std::result::Result<
74        crate::operation::create_fleet::CreateFleetOutput,
75        ::aws_smithy_runtime_api::client::result::SdkError<
76            crate::operation::create_fleet::CreateFleetError,
77            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
78        >,
79    > {
80        let input = self
81            .inner
82            .build()
83            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
84        let runtime_plugins = crate::operation::create_fleet::CreateFleet::operation_runtime_plugins(
85            self.handle.runtime_plugins.clone(),
86            &self.handle.conf,
87            self.config_override,
88        );
89        crate::operation::create_fleet::CreateFleet::orchestrate(&runtime_plugins, input).await
90    }
91
92    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
93    pub fn customize(
94        self,
95    ) -> crate::client::customize::CustomizableOperation<
96        crate::operation::create_fleet::CreateFleetOutput,
97        crate::operation::create_fleet::CreateFleetError,
98        Self,
99    > {
100        crate::client::customize::CustomizableOperation::new(self)
101    }
102    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
103        self.set_config_override(::std::option::Option::Some(config_override.into()));
104        self
105    }
106
107    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
108        self.config_override = config_override;
109        self
110    }
111    /// <p>A unique name for the fleet.</p>
112    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
113        self.inner = self.inner.name(input.into());
114        self
115    }
116    /// <p>A unique name for the fleet.</p>
117    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
118        self.inner = self.inner.set_name(input);
119        self
120    }
121    /// <p>A unique name for the fleet.</p>
122    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
123        self.inner.get_name()
124    }
125    /// <p>The name of the image used to create the fleet.</p>
126    pub fn image_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
127        self.inner = self.inner.image_name(input.into());
128        self
129    }
130    /// <p>The name of the image used to create the fleet.</p>
131    pub fn set_image_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
132        self.inner = self.inner.set_image_name(input);
133        self
134    }
135    /// <p>The name of the image used to create the fleet.</p>
136    pub fn get_image_name(&self) -> &::std::option::Option<::std::string::String> {
137        self.inner.get_image_name()
138    }
139    /// <p>The ARN of the public, private, or shared image to use.</p>
140    pub fn image_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
141        self.inner = self.inner.image_arn(input.into());
142        self
143    }
144    /// <p>The ARN of the public, private, or shared image to use.</p>
145    pub fn set_image_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
146        self.inner = self.inner.set_image_arn(input);
147        self
148    }
149    /// <p>The ARN of the public, private, or shared image to use.</p>
150    pub fn get_image_arn(&self) -> &::std::option::Option<::std::string::String> {
151        self.inner.get_image_arn()
152    }
153    /// <p>The instance type to use when launching fleet instances. The following instance types are available:</p>
154    /// <ul>
155    /// <li>
156    /// <p>stream.standard.small</p></li>
157    /// <li>
158    /// <p>stream.standard.medium</p></li>
159    /// <li>
160    /// <p>stream.standard.large</p></li>
161    /// <li>
162    /// <p>stream.standard.xlarge</p></li>
163    /// <li>
164    /// <p>stream.standard.2xlarge</p></li>
165    /// <li>
166    /// <p>stream.compute.large</p></li>
167    /// <li>
168    /// <p>stream.compute.xlarge</p></li>
169    /// <li>
170    /// <p>stream.compute.2xlarge</p></li>
171    /// <li>
172    /// <p>stream.compute.4xlarge</p></li>
173    /// <li>
174    /// <p>stream.compute.8xlarge</p></li>
175    /// <li>
176    /// <p>stream.memory.large</p></li>
177    /// <li>
178    /// <p>stream.memory.xlarge</p></li>
179    /// <li>
180    /// <p>stream.memory.2xlarge</p></li>
181    /// <li>
182    /// <p>stream.memory.4xlarge</p></li>
183    /// <li>
184    /// <p>stream.memory.8xlarge</p></li>
185    /// <li>
186    /// <p>stream.memory.z1d.large</p></li>
187    /// <li>
188    /// <p>stream.memory.z1d.xlarge</p></li>
189    /// <li>
190    /// <p>stream.memory.z1d.2xlarge</p></li>
191    /// <li>
192    /// <p>stream.memory.z1d.3xlarge</p></li>
193    /// <li>
194    /// <p>stream.memory.z1d.6xlarge</p></li>
195    /// <li>
196    /// <p>stream.memory.z1d.12xlarge</p></li>
197    /// <li>
198    /// <p>stream.graphics.g4dn.xlarge</p></li>
199    /// <li>
200    /// <p>stream.graphics.g4dn.2xlarge</p></li>
201    /// <li>
202    /// <p>stream.graphics.g4dn.4xlarge</p></li>
203    /// <li>
204    /// <p>stream.graphics.g4dn.8xlarge</p></li>
205    /// <li>
206    /// <p>stream.graphics.g4dn.12xlarge</p></li>
207    /// <li>
208    /// <p>stream.graphics.g4dn.16xlarge</p></li>
209    /// <li>
210    /// <p>stream.graphics.g5.xlarge</p></li>
211    /// <li>
212    /// <p>stream.graphics.g5.2xlarge</p></li>
213    /// <li>
214    /// <p>stream.graphics.g5.4xlarge</p></li>
215    /// <li>
216    /// <p>stream.graphics.g5.8xlarge</p></li>
217    /// <li>
218    /// <p>stream.graphics.g5.12xlarge</p></li>
219    /// <li>
220    /// <p>stream.graphics.g5.16xlarge</p></li>
221    /// <li>
222    /// <p>stream.graphics.g5.24xlarge</p></li>
223    /// <li>
224    /// <p>stream.graphics.g6.xlarge</p></li>
225    /// <li>
226    /// <p>stream.graphics.g6.2xlarge</p></li>
227    /// <li>
228    /// <p>stream.graphics.g6.4xlarge</p></li>
229    /// <li>
230    /// <p>stream.graphics.g6.8xlarge</p></li>
231    /// <li>
232    /// <p>stream.graphics.g6.16xlarge</p></li>
233    /// <li>
234    /// <p>stream.graphics.g6.12xlarge</p></li>
235    /// <li>
236    /// <p>stream.graphics.g6.24xlarge</p></li>
237    /// <li>
238    /// <p>stream.graphics.gr6.4xlarge</p></li>
239    /// <li>
240    /// <p>stream.graphics.gr6.8xlarge</p></li>
241    /// <li>
242    /// <p>stream.graphics.g6f.large</p></li>
243    /// <li>
244    /// <p>stream.graphics.g6f.xlarge</p></li>
245    /// <li>
246    /// <p>stream.graphics.g6f.2xlarge</p></li>
247    /// <li>
248    /// <p>stream.graphics.g6f.4xlarge</p></li>
249    /// <li>
250    /// <p>stream.graphics.gr6f.4xlarge</p></li>
251    /// </ul>
252    /// <p>The following instance types are available for Elastic fleets:</p>
253    /// <ul>
254    /// <li>
255    /// <p>stream.standard.small</p></li>
256    /// <li>
257    /// <p>stream.standard.medium</p></li>
258    /// <li>
259    /// <p>stream.standard.large</p></li>
260    /// <li>
261    /// <p>stream.standard.xlarge</p></li>
262    /// <li>
263    /// <p>stream.standard.2xlarge</p></li>
264    /// </ul>
265    pub fn instance_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
266        self.inner = self.inner.instance_type(input.into());
267        self
268    }
269    /// <p>The instance type to use when launching fleet instances. The following instance types are available:</p>
270    /// <ul>
271    /// <li>
272    /// <p>stream.standard.small</p></li>
273    /// <li>
274    /// <p>stream.standard.medium</p></li>
275    /// <li>
276    /// <p>stream.standard.large</p></li>
277    /// <li>
278    /// <p>stream.standard.xlarge</p></li>
279    /// <li>
280    /// <p>stream.standard.2xlarge</p></li>
281    /// <li>
282    /// <p>stream.compute.large</p></li>
283    /// <li>
284    /// <p>stream.compute.xlarge</p></li>
285    /// <li>
286    /// <p>stream.compute.2xlarge</p></li>
287    /// <li>
288    /// <p>stream.compute.4xlarge</p></li>
289    /// <li>
290    /// <p>stream.compute.8xlarge</p></li>
291    /// <li>
292    /// <p>stream.memory.large</p></li>
293    /// <li>
294    /// <p>stream.memory.xlarge</p></li>
295    /// <li>
296    /// <p>stream.memory.2xlarge</p></li>
297    /// <li>
298    /// <p>stream.memory.4xlarge</p></li>
299    /// <li>
300    /// <p>stream.memory.8xlarge</p></li>
301    /// <li>
302    /// <p>stream.memory.z1d.large</p></li>
303    /// <li>
304    /// <p>stream.memory.z1d.xlarge</p></li>
305    /// <li>
306    /// <p>stream.memory.z1d.2xlarge</p></li>
307    /// <li>
308    /// <p>stream.memory.z1d.3xlarge</p></li>
309    /// <li>
310    /// <p>stream.memory.z1d.6xlarge</p></li>
311    /// <li>
312    /// <p>stream.memory.z1d.12xlarge</p></li>
313    /// <li>
314    /// <p>stream.graphics.g4dn.xlarge</p></li>
315    /// <li>
316    /// <p>stream.graphics.g4dn.2xlarge</p></li>
317    /// <li>
318    /// <p>stream.graphics.g4dn.4xlarge</p></li>
319    /// <li>
320    /// <p>stream.graphics.g4dn.8xlarge</p></li>
321    /// <li>
322    /// <p>stream.graphics.g4dn.12xlarge</p></li>
323    /// <li>
324    /// <p>stream.graphics.g4dn.16xlarge</p></li>
325    /// <li>
326    /// <p>stream.graphics.g5.xlarge</p></li>
327    /// <li>
328    /// <p>stream.graphics.g5.2xlarge</p></li>
329    /// <li>
330    /// <p>stream.graphics.g5.4xlarge</p></li>
331    /// <li>
332    /// <p>stream.graphics.g5.8xlarge</p></li>
333    /// <li>
334    /// <p>stream.graphics.g5.12xlarge</p></li>
335    /// <li>
336    /// <p>stream.graphics.g5.16xlarge</p></li>
337    /// <li>
338    /// <p>stream.graphics.g5.24xlarge</p></li>
339    /// <li>
340    /// <p>stream.graphics.g6.xlarge</p></li>
341    /// <li>
342    /// <p>stream.graphics.g6.2xlarge</p></li>
343    /// <li>
344    /// <p>stream.graphics.g6.4xlarge</p></li>
345    /// <li>
346    /// <p>stream.graphics.g6.8xlarge</p></li>
347    /// <li>
348    /// <p>stream.graphics.g6.16xlarge</p></li>
349    /// <li>
350    /// <p>stream.graphics.g6.12xlarge</p></li>
351    /// <li>
352    /// <p>stream.graphics.g6.24xlarge</p></li>
353    /// <li>
354    /// <p>stream.graphics.gr6.4xlarge</p></li>
355    /// <li>
356    /// <p>stream.graphics.gr6.8xlarge</p></li>
357    /// <li>
358    /// <p>stream.graphics.g6f.large</p></li>
359    /// <li>
360    /// <p>stream.graphics.g6f.xlarge</p></li>
361    /// <li>
362    /// <p>stream.graphics.g6f.2xlarge</p></li>
363    /// <li>
364    /// <p>stream.graphics.g6f.4xlarge</p></li>
365    /// <li>
366    /// <p>stream.graphics.gr6f.4xlarge</p></li>
367    /// </ul>
368    /// <p>The following instance types are available for Elastic fleets:</p>
369    /// <ul>
370    /// <li>
371    /// <p>stream.standard.small</p></li>
372    /// <li>
373    /// <p>stream.standard.medium</p></li>
374    /// <li>
375    /// <p>stream.standard.large</p></li>
376    /// <li>
377    /// <p>stream.standard.xlarge</p></li>
378    /// <li>
379    /// <p>stream.standard.2xlarge</p></li>
380    /// </ul>
381    pub fn set_instance_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
382        self.inner = self.inner.set_instance_type(input);
383        self
384    }
385    /// <p>The instance type to use when launching fleet instances. The following instance types are available:</p>
386    /// <ul>
387    /// <li>
388    /// <p>stream.standard.small</p></li>
389    /// <li>
390    /// <p>stream.standard.medium</p></li>
391    /// <li>
392    /// <p>stream.standard.large</p></li>
393    /// <li>
394    /// <p>stream.standard.xlarge</p></li>
395    /// <li>
396    /// <p>stream.standard.2xlarge</p></li>
397    /// <li>
398    /// <p>stream.compute.large</p></li>
399    /// <li>
400    /// <p>stream.compute.xlarge</p></li>
401    /// <li>
402    /// <p>stream.compute.2xlarge</p></li>
403    /// <li>
404    /// <p>stream.compute.4xlarge</p></li>
405    /// <li>
406    /// <p>stream.compute.8xlarge</p></li>
407    /// <li>
408    /// <p>stream.memory.large</p></li>
409    /// <li>
410    /// <p>stream.memory.xlarge</p></li>
411    /// <li>
412    /// <p>stream.memory.2xlarge</p></li>
413    /// <li>
414    /// <p>stream.memory.4xlarge</p></li>
415    /// <li>
416    /// <p>stream.memory.8xlarge</p></li>
417    /// <li>
418    /// <p>stream.memory.z1d.large</p></li>
419    /// <li>
420    /// <p>stream.memory.z1d.xlarge</p></li>
421    /// <li>
422    /// <p>stream.memory.z1d.2xlarge</p></li>
423    /// <li>
424    /// <p>stream.memory.z1d.3xlarge</p></li>
425    /// <li>
426    /// <p>stream.memory.z1d.6xlarge</p></li>
427    /// <li>
428    /// <p>stream.memory.z1d.12xlarge</p></li>
429    /// <li>
430    /// <p>stream.graphics.g4dn.xlarge</p></li>
431    /// <li>
432    /// <p>stream.graphics.g4dn.2xlarge</p></li>
433    /// <li>
434    /// <p>stream.graphics.g4dn.4xlarge</p></li>
435    /// <li>
436    /// <p>stream.graphics.g4dn.8xlarge</p></li>
437    /// <li>
438    /// <p>stream.graphics.g4dn.12xlarge</p></li>
439    /// <li>
440    /// <p>stream.graphics.g4dn.16xlarge</p></li>
441    /// <li>
442    /// <p>stream.graphics.g5.xlarge</p></li>
443    /// <li>
444    /// <p>stream.graphics.g5.2xlarge</p></li>
445    /// <li>
446    /// <p>stream.graphics.g5.4xlarge</p></li>
447    /// <li>
448    /// <p>stream.graphics.g5.8xlarge</p></li>
449    /// <li>
450    /// <p>stream.graphics.g5.12xlarge</p></li>
451    /// <li>
452    /// <p>stream.graphics.g5.16xlarge</p></li>
453    /// <li>
454    /// <p>stream.graphics.g5.24xlarge</p></li>
455    /// <li>
456    /// <p>stream.graphics.g6.xlarge</p></li>
457    /// <li>
458    /// <p>stream.graphics.g6.2xlarge</p></li>
459    /// <li>
460    /// <p>stream.graphics.g6.4xlarge</p></li>
461    /// <li>
462    /// <p>stream.graphics.g6.8xlarge</p></li>
463    /// <li>
464    /// <p>stream.graphics.g6.16xlarge</p></li>
465    /// <li>
466    /// <p>stream.graphics.g6.12xlarge</p></li>
467    /// <li>
468    /// <p>stream.graphics.g6.24xlarge</p></li>
469    /// <li>
470    /// <p>stream.graphics.gr6.4xlarge</p></li>
471    /// <li>
472    /// <p>stream.graphics.gr6.8xlarge</p></li>
473    /// <li>
474    /// <p>stream.graphics.g6f.large</p></li>
475    /// <li>
476    /// <p>stream.graphics.g6f.xlarge</p></li>
477    /// <li>
478    /// <p>stream.graphics.g6f.2xlarge</p></li>
479    /// <li>
480    /// <p>stream.graphics.g6f.4xlarge</p></li>
481    /// <li>
482    /// <p>stream.graphics.gr6f.4xlarge</p></li>
483    /// </ul>
484    /// <p>The following instance types are available for Elastic fleets:</p>
485    /// <ul>
486    /// <li>
487    /// <p>stream.standard.small</p></li>
488    /// <li>
489    /// <p>stream.standard.medium</p></li>
490    /// <li>
491    /// <p>stream.standard.large</p></li>
492    /// <li>
493    /// <p>stream.standard.xlarge</p></li>
494    /// <li>
495    /// <p>stream.standard.2xlarge</p></li>
496    /// </ul>
497    pub fn get_instance_type(&self) -> &::std::option::Option<::std::string::String> {
498        self.inner.get_instance_type()
499    }
500    /// <p>The fleet type.</p>
501    /// <dl>
502    /// <dt>
503    /// ALWAYS_ON
504    /// </dt>
505    /// <dd>
506    /// <p>Provides users with instant-on access to their apps. You are charged for all running instances in your fleet, even if no users are streaming apps.</p>
507    /// </dd>
508    /// <dt>
509    /// ON_DEMAND
510    /// </dt>
511    /// <dd>
512    /// <p>Provide users with access to applications after they connect, which takes one to two minutes. You are charged for instance streaming when users are connected and a small hourly fee for instances that are not streaming apps.</p>
513    /// </dd>
514    /// </dl>
515    pub fn fleet_type(mut self, input: crate::types::FleetType) -> Self {
516        self.inner = self.inner.fleet_type(input);
517        self
518    }
519    /// <p>The fleet type.</p>
520    /// <dl>
521    /// <dt>
522    /// ALWAYS_ON
523    /// </dt>
524    /// <dd>
525    /// <p>Provides users with instant-on access to their apps. You are charged for all running instances in your fleet, even if no users are streaming apps.</p>
526    /// </dd>
527    /// <dt>
528    /// ON_DEMAND
529    /// </dt>
530    /// <dd>
531    /// <p>Provide users with access to applications after they connect, which takes one to two minutes. You are charged for instance streaming when users are connected and a small hourly fee for instances that are not streaming apps.</p>
532    /// </dd>
533    /// </dl>
534    pub fn set_fleet_type(mut self, input: ::std::option::Option<crate::types::FleetType>) -> Self {
535        self.inner = self.inner.set_fleet_type(input);
536        self
537    }
538    /// <p>The fleet type.</p>
539    /// <dl>
540    /// <dt>
541    /// ALWAYS_ON
542    /// </dt>
543    /// <dd>
544    /// <p>Provides users with instant-on access to their apps. You are charged for all running instances in your fleet, even if no users are streaming apps.</p>
545    /// </dd>
546    /// <dt>
547    /// ON_DEMAND
548    /// </dt>
549    /// <dd>
550    /// <p>Provide users with access to applications after they connect, which takes one to two minutes. You are charged for instance streaming when users are connected and a small hourly fee for instances that are not streaming apps.</p>
551    /// </dd>
552    /// </dl>
553    pub fn get_fleet_type(&self) -> &::std::option::Option<crate::types::FleetType> {
554        self.inner.get_fleet_type()
555    }
556    /// <p>The desired capacity for the fleet. This is not allowed for Elastic fleets. For Elastic fleets, specify MaxConcurrentSessions instead.</p>
557    pub fn compute_capacity(mut self, input: crate::types::ComputeCapacity) -> Self {
558        self.inner = self.inner.compute_capacity(input);
559        self
560    }
561    /// <p>The desired capacity for the fleet. This is not allowed for Elastic fleets. For Elastic fleets, specify MaxConcurrentSessions instead.</p>
562    pub fn set_compute_capacity(mut self, input: ::std::option::Option<crate::types::ComputeCapacity>) -> Self {
563        self.inner = self.inner.set_compute_capacity(input);
564        self
565    }
566    /// <p>The desired capacity for the fleet. This is not allowed for Elastic fleets. For Elastic fleets, specify MaxConcurrentSessions instead.</p>
567    pub fn get_compute_capacity(&self) -> &::std::option::Option<crate::types::ComputeCapacity> {
568        self.inner.get_compute_capacity()
569    }
570    /// <p>The VPC configuration for the fleet. This is required for Elastic fleets, but not required for other fleet types. Elastic fleets require that you specify at least two subnets in different availability zones.</p>
571    pub fn vpc_config(mut self, input: crate::types::VpcConfig) -> Self {
572        self.inner = self.inner.vpc_config(input);
573        self
574    }
575    /// <p>The VPC configuration for the fleet. This is required for Elastic fleets, but not required for other fleet types. Elastic fleets require that you specify at least two subnets in different availability zones.</p>
576    pub fn set_vpc_config(mut self, input: ::std::option::Option<crate::types::VpcConfig>) -> Self {
577        self.inner = self.inner.set_vpc_config(input);
578        self
579    }
580    /// <p>The VPC configuration for the fleet. This is required for Elastic fleets, but not required for other fleet types. Elastic fleets require that you specify at least two subnets in different availability zones.</p>
581    pub fn get_vpc_config(&self) -> &::std::option::Option<crate::types::VpcConfig> {
582        self.inner.get_vpc_config()
583    }
584    /// <p>The maximum amount of time that a streaming session can remain active, in seconds. If users are still connected to a streaming instance five minutes before this limit is reached, they are prompted to save any open documents before being disconnected. After this time elapses, the instance is terminated and replaced by a new instance.</p>
585    /// <p>Specify a value between 600 and 432000.</p>
586    pub fn max_user_duration_in_seconds(mut self, input: i32) -> Self {
587        self.inner = self.inner.max_user_duration_in_seconds(input);
588        self
589    }
590    /// <p>The maximum amount of time that a streaming session can remain active, in seconds. If users are still connected to a streaming instance five minutes before this limit is reached, they are prompted to save any open documents before being disconnected. After this time elapses, the instance is terminated and replaced by a new instance.</p>
591    /// <p>Specify a value between 600 and 432000.</p>
592    pub fn set_max_user_duration_in_seconds(mut self, input: ::std::option::Option<i32>) -> Self {
593        self.inner = self.inner.set_max_user_duration_in_seconds(input);
594        self
595    }
596    /// <p>The maximum amount of time that a streaming session can remain active, in seconds. If users are still connected to a streaming instance five minutes before this limit is reached, they are prompted to save any open documents before being disconnected. After this time elapses, the instance is terminated and replaced by a new instance.</p>
597    /// <p>Specify a value between 600 and 432000.</p>
598    pub fn get_max_user_duration_in_seconds(&self) -> &::std::option::Option<i32> {
599        self.inner.get_max_user_duration_in_seconds()
600    }
601    /// <p>The amount of time that a streaming session remains active after users disconnect. If users try to reconnect to the streaming session after a disconnection or network interruption within this time interval, they are connected to their previous session. Otherwise, they are connected to a new session with a new streaming instance.</p>
602    /// <p>Specify a value between 60 and 36000.</p>
603    pub fn disconnect_timeout_in_seconds(mut self, input: i32) -> Self {
604        self.inner = self.inner.disconnect_timeout_in_seconds(input);
605        self
606    }
607    /// <p>The amount of time that a streaming session remains active after users disconnect. If users try to reconnect to the streaming session after a disconnection or network interruption within this time interval, they are connected to their previous session. Otherwise, they are connected to a new session with a new streaming instance.</p>
608    /// <p>Specify a value between 60 and 36000.</p>
609    pub fn set_disconnect_timeout_in_seconds(mut self, input: ::std::option::Option<i32>) -> Self {
610        self.inner = self.inner.set_disconnect_timeout_in_seconds(input);
611        self
612    }
613    /// <p>The amount of time that a streaming session remains active after users disconnect. If users try to reconnect to the streaming session after a disconnection or network interruption within this time interval, they are connected to their previous session. Otherwise, they are connected to a new session with a new streaming instance.</p>
614    /// <p>Specify a value between 60 and 36000.</p>
615    pub fn get_disconnect_timeout_in_seconds(&self) -> &::std::option::Option<i32> {
616        self.inner.get_disconnect_timeout_in_seconds()
617    }
618    /// <p>The description to display.</p>
619    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
620        self.inner = self.inner.description(input.into());
621        self
622    }
623    /// <p>The description to display.</p>
624    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
625        self.inner = self.inner.set_description(input);
626        self
627    }
628    /// <p>The description to display.</p>
629    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
630        self.inner.get_description()
631    }
632    /// <p>The fleet name to display.</p>
633    pub fn display_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
634        self.inner = self.inner.display_name(input.into());
635        self
636    }
637    /// <p>The fleet name to display.</p>
638    pub fn set_display_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
639        self.inner = self.inner.set_display_name(input);
640        self
641    }
642    /// <p>The fleet name to display.</p>
643    pub fn get_display_name(&self) -> &::std::option::Option<::std::string::String> {
644        self.inner.get_display_name()
645    }
646    /// <p>Enables or disables default internet access for the fleet.</p>
647    pub fn enable_default_internet_access(mut self, input: bool) -> Self {
648        self.inner = self.inner.enable_default_internet_access(input);
649        self
650    }
651    /// <p>Enables or disables default internet access for the fleet.</p>
652    pub fn set_enable_default_internet_access(mut self, input: ::std::option::Option<bool>) -> Self {
653        self.inner = self.inner.set_enable_default_internet_access(input);
654        self
655    }
656    /// <p>Enables or disables default internet access for the fleet.</p>
657    pub fn get_enable_default_internet_access(&self) -> &::std::option::Option<bool> {
658        self.inner.get_enable_default_internet_access()
659    }
660    /// <p>The name of the directory and organizational unit (OU) to use to join the fleet to a Microsoft Active Directory domain. This is not allowed for Elastic fleets.</p>
661    pub fn domain_join_info(mut self, input: crate::types::DomainJoinInfo) -> Self {
662        self.inner = self.inner.domain_join_info(input);
663        self
664    }
665    /// <p>The name of the directory and organizational unit (OU) to use to join the fleet to a Microsoft Active Directory domain. This is not allowed for Elastic fleets.</p>
666    pub fn set_domain_join_info(mut self, input: ::std::option::Option<crate::types::DomainJoinInfo>) -> Self {
667        self.inner = self.inner.set_domain_join_info(input);
668        self
669    }
670    /// <p>The name of the directory and organizational unit (OU) to use to join the fleet to a Microsoft Active Directory domain. This is not allowed for Elastic fleets.</p>
671    pub fn get_domain_join_info(&self) -> &::std::option::Option<crate::types::DomainJoinInfo> {
672        self.inner.get_domain_join_info()
673    }
674    ///
675    /// Adds a key-value pair to `Tags`.
676    ///
677    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
678    ///
679    /// <p>The tags to associate with the fleet. A tag is a key-value pair, and the value is optional. For example, Environment=Test. If you do not specify a value, Environment=.</p>
680    /// <p>If you do not specify a value, the value is set to an empty string.</p>
681    /// <p>Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following special characters:</p>
682    /// <p>_ . : / = + \ - @</p>
683    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/tagging-basic.html">Tagging Your Resources</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
684    pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
685        self.inner = self.inner.tags(k.into(), v.into());
686        self
687    }
688    /// <p>The tags to associate with the fleet. A tag is a key-value pair, and the value is optional. For example, Environment=Test. If you do not specify a value, Environment=.</p>
689    /// <p>If you do not specify a value, the value is set to an empty string.</p>
690    /// <p>Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following special characters:</p>
691    /// <p>_ . : / = + \ - @</p>
692    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/tagging-basic.html">Tagging Your Resources</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
693    pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
694        self.inner = self.inner.set_tags(input);
695        self
696    }
697    /// <p>The tags to associate with the fleet. A tag is a key-value pair, and the value is optional. For example, Environment=Test. If you do not specify a value, Environment=.</p>
698    /// <p>If you do not specify a value, the value is set to an empty string.</p>
699    /// <p>Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following special characters:</p>
700    /// <p>_ . : / = + \ - @</p>
701    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/tagging-basic.html">Tagging Your Resources</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
702    pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
703        self.inner.get_tags()
704    }
705    /// <p>The amount of time that users can be idle (inactive) before they are disconnected from their streaming session and the <code>DisconnectTimeoutInSeconds</code> time interval begins. Users are notified before they are disconnected due to inactivity. If they try to reconnect to the streaming session before the time interval specified in <code>DisconnectTimeoutInSeconds</code> elapses, they are connected to their previous session. Users are considered idle when they stop providing keyboard or mouse input during their streaming session. File uploads and downloads, audio in, audio out, and pixels changing do not qualify as user activity. If users continue to be idle after the time interval in <code>IdleDisconnectTimeoutInSeconds</code> elapses, they are disconnected.</p>
706    /// <p>To prevent users from being disconnected due to inactivity, specify a value of 0. Otherwise, specify a value between 60 and 36000. The default value is 0.</p><note>
707    /// <p>If you enable this feature, we recommend that you specify a value that corresponds exactly to a whole number of minutes (for example, 60, 120, and 180). If you don't do this, the value is rounded to the nearest minute. For example, if you specify a value of 70, users are disconnected after 1 minute of inactivity. If you specify a value that is at the midpoint between two different minutes, the value is rounded up. For example, if you specify a value of 90, users are disconnected after 2 minutes of inactivity.</p>
708    /// </note>
709    pub fn idle_disconnect_timeout_in_seconds(mut self, input: i32) -> Self {
710        self.inner = self.inner.idle_disconnect_timeout_in_seconds(input);
711        self
712    }
713    /// <p>The amount of time that users can be idle (inactive) before they are disconnected from their streaming session and the <code>DisconnectTimeoutInSeconds</code> time interval begins. Users are notified before they are disconnected due to inactivity. If they try to reconnect to the streaming session before the time interval specified in <code>DisconnectTimeoutInSeconds</code> elapses, they are connected to their previous session. Users are considered idle when they stop providing keyboard or mouse input during their streaming session. File uploads and downloads, audio in, audio out, and pixels changing do not qualify as user activity. If users continue to be idle after the time interval in <code>IdleDisconnectTimeoutInSeconds</code> elapses, they are disconnected.</p>
714    /// <p>To prevent users from being disconnected due to inactivity, specify a value of 0. Otherwise, specify a value between 60 and 36000. The default value is 0.</p><note>
715    /// <p>If you enable this feature, we recommend that you specify a value that corresponds exactly to a whole number of minutes (for example, 60, 120, and 180). If you don't do this, the value is rounded to the nearest minute. For example, if you specify a value of 70, users are disconnected after 1 minute of inactivity. If you specify a value that is at the midpoint between two different minutes, the value is rounded up. For example, if you specify a value of 90, users are disconnected after 2 minutes of inactivity.</p>
716    /// </note>
717    pub fn set_idle_disconnect_timeout_in_seconds(mut self, input: ::std::option::Option<i32>) -> Self {
718        self.inner = self.inner.set_idle_disconnect_timeout_in_seconds(input);
719        self
720    }
721    /// <p>The amount of time that users can be idle (inactive) before they are disconnected from their streaming session and the <code>DisconnectTimeoutInSeconds</code> time interval begins. Users are notified before they are disconnected due to inactivity. If they try to reconnect to the streaming session before the time interval specified in <code>DisconnectTimeoutInSeconds</code> elapses, they are connected to their previous session. Users are considered idle when they stop providing keyboard or mouse input during their streaming session. File uploads and downloads, audio in, audio out, and pixels changing do not qualify as user activity. If users continue to be idle after the time interval in <code>IdleDisconnectTimeoutInSeconds</code> elapses, they are disconnected.</p>
722    /// <p>To prevent users from being disconnected due to inactivity, specify a value of 0. Otherwise, specify a value between 60 and 36000. The default value is 0.</p><note>
723    /// <p>If you enable this feature, we recommend that you specify a value that corresponds exactly to a whole number of minutes (for example, 60, 120, and 180). If you don't do this, the value is rounded to the nearest minute. For example, if you specify a value of 70, users are disconnected after 1 minute of inactivity. If you specify a value that is at the midpoint between two different minutes, the value is rounded up. For example, if you specify a value of 90, users are disconnected after 2 minutes of inactivity.</p>
724    /// </note>
725    pub fn get_idle_disconnect_timeout_in_seconds(&self) -> &::std::option::Option<i32> {
726        self.inner.get_idle_disconnect_timeout_in_seconds()
727    }
728    /// <p>The Amazon Resource Name (ARN) of the IAM role to apply to the fleet. To assume a role, a fleet instance calls the AWS Security Token Service (STS) <code>AssumeRole</code> API operation and passes the ARN of the role to use. The operation creates a new session with temporary credentials. WorkSpaces Applications retrieves the temporary credentials and creates the <b>appstream_machine_role</b> credential profile on the instance.</p>
729    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/using-iam-roles-to-grant-permissions-to-applications-scripts-streaming-instances.html">Using an IAM Role to Grant Permissions to Applications and Scripts Running on WorkSpaces Applications Streaming Instances</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
730    pub fn iam_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
731        self.inner = self.inner.iam_role_arn(input.into());
732        self
733    }
734    /// <p>The Amazon Resource Name (ARN) of the IAM role to apply to the fleet. To assume a role, a fleet instance calls the AWS Security Token Service (STS) <code>AssumeRole</code> API operation and passes the ARN of the role to use. The operation creates a new session with temporary credentials. WorkSpaces Applications retrieves the temporary credentials and creates the <b>appstream_machine_role</b> credential profile on the instance.</p>
735    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/using-iam-roles-to-grant-permissions-to-applications-scripts-streaming-instances.html">Using an IAM Role to Grant Permissions to Applications and Scripts Running on WorkSpaces Applications Streaming Instances</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
736    pub fn set_iam_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
737        self.inner = self.inner.set_iam_role_arn(input);
738        self
739    }
740    /// <p>The Amazon Resource Name (ARN) of the IAM role to apply to the fleet. To assume a role, a fleet instance calls the AWS Security Token Service (STS) <code>AssumeRole</code> API operation and passes the ARN of the role to use. The operation creates a new session with temporary credentials. WorkSpaces Applications retrieves the temporary credentials and creates the <b>appstream_machine_role</b> credential profile on the instance.</p>
741    /// <p>For more information, see <a href="https://docs.aws.amazon.com/appstream2/latest/developerguide/using-iam-roles-to-grant-permissions-to-applications-scripts-streaming-instances.html">Using an IAM Role to Grant Permissions to Applications and Scripts Running on WorkSpaces Applications Streaming Instances</a> in the <i>Amazon WorkSpaces Applications Administration Guide</i>.</p>
742    pub fn get_iam_role_arn(&self) -> &::std::option::Option<::std::string::String> {
743        self.inner.get_iam_role_arn()
744    }
745    /// <p>The WorkSpaces Applications view that is displayed to your users when they stream from the fleet. When <code>APP</code> is specified, only the windows of applications opened by users display. When <code>DESKTOP</code> is specified, the standard desktop that is provided by the operating system displays.</p>
746    /// <p>The default value is <code>APP</code>.</p>
747    pub fn stream_view(mut self, input: crate::types::StreamView) -> Self {
748        self.inner = self.inner.stream_view(input);
749        self
750    }
751    /// <p>The WorkSpaces Applications view that is displayed to your users when they stream from the fleet. When <code>APP</code> is specified, only the windows of applications opened by users display. When <code>DESKTOP</code> is specified, the standard desktop that is provided by the operating system displays.</p>
752    /// <p>The default value is <code>APP</code>.</p>
753    pub fn set_stream_view(mut self, input: ::std::option::Option<crate::types::StreamView>) -> Self {
754        self.inner = self.inner.set_stream_view(input);
755        self
756    }
757    /// <p>The WorkSpaces Applications view that is displayed to your users when they stream from the fleet. When <code>APP</code> is specified, only the windows of applications opened by users display. When <code>DESKTOP</code> is specified, the standard desktop that is provided by the operating system displays.</p>
758    /// <p>The default value is <code>APP</code>.</p>
759    pub fn get_stream_view(&self) -> &::std::option::Option<crate::types::StreamView> {
760        self.inner.get_stream_view()
761    }
762    /// <p>The fleet platform. WINDOWS_SERVER_2019, AMAZON_LINUX2 and UBUNTU_PRO_2404 are supported for Elastic fleets.</p>
763    pub fn platform(mut self, input: crate::types::PlatformType) -> Self {
764        self.inner = self.inner.platform(input);
765        self
766    }
767    /// <p>The fleet platform. WINDOWS_SERVER_2019, AMAZON_LINUX2 and UBUNTU_PRO_2404 are supported for Elastic fleets.</p>
768    pub fn set_platform(mut self, input: ::std::option::Option<crate::types::PlatformType>) -> Self {
769        self.inner = self.inner.set_platform(input);
770        self
771    }
772    /// <p>The fleet platform. WINDOWS_SERVER_2019, AMAZON_LINUX2 and UBUNTU_PRO_2404 are supported for Elastic fleets.</p>
773    pub fn get_platform(&self) -> &::std::option::Option<crate::types::PlatformType> {
774        self.inner.get_platform()
775    }
776    /// <p>The maximum concurrent sessions of the Elastic fleet. This is required for Elastic fleets, and not allowed for other fleet types.</p>
777    pub fn max_concurrent_sessions(mut self, input: i32) -> Self {
778        self.inner = self.inner.max_concurrent_sessions(input);
779        self
780    }
781    /// <p>The maximum concurrent sessions of the Elastic fleet. This is required for Elastic fleets, and not allowed for other fleet types.</p>
782    pub fn set_max_concurrent_sessions(mut self, input: ::std::option::Option<i32>) -> Self {
783        self.inner = self.inner.set_max_concurrent_sessions(input);
784        self
785    }
786    /// <p>The maximum concurrent sessions of the Elastic fleet. This is required for Elastic fleets, and not allowed for other fleet types.</p>
787    pub fn get_max_concurrent_sessions(&self) -> &::std::option::Option<i32> {
788        self.inner.get_max_concurrent_sessions()
789    }
790    ///
791    /// Appends an item to `UsbDeviceFilterStrings`.
792    ///
793    /// To override the contents of this collection use [`set_usb_device_filter_strings`](Self::set_usb_device_filter_strings).
794    ///
795    /// <p>The USB device filter strings that specify which USB devices a user can redirect to the fleet streaming session, when using the Windows native client. This is allowed but not required for Elastic fleets.</p>
796    pub fn usb_device_filter_strings(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
797        self.inner = self.inner.usb_device_filter_strings(input.into());
798        self
799    }
800    /// <p>The USB device filter strings that specify which USB devices a user can redirect to the fleet streaming session, when using the Windows native client. This is allowed but not required for Elastic fleets.</p>
801    pub fn set_usb_device_filter_strings(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
802        self.inner = self.inner.set_usb_device_filter_strings(input);
803        self
804    }
805    /// <p>The USB device filter strings that specify which USB devices a user can redirect to the fleet streaming session, when using the Windows native client. This is allowed but not required for Elastic fleets.</p>
806    pub fn get_usb_device_filter_strings(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
807        self.inner.get_usb_device_filter_strings()
808    }
809    /// <p>The S3 location of the session scripts configuration zip file. This only applies to Elastic fleets.</p>
810    pub fn session_script_s3_location(mut self, input: crate::types::S3Location) -> Self {
811        self.inner = self.inner.session_script_s3_location(input);
812        self
813    }
814    /// <p>The S3 location of the session scripts configuration zip file. This only applies to Elastic fleets.</p>
815    pub fn set_session_script_s3_location(mut self, input: ::std::option::Option<crate::types::S3Location>) -> Self {
816        self.inner = self.inner.set_session_script_s3_location(input);
817        self
818    }
819    /// <p>The S3 location of the session scripts configuration zip file. This only applies to Elastic fleets.</p>
820    pub fn get_session_script_s3_location(&self) -> &::std::option::Option<crate::types::S3Location> {
821        self.inner.get_session_script_s3_location()
822    }
823    /// <p>The maximum number of user sessions on an instance. This only applies to multi-session fleets.</p>
824    pub fn max_sessions_per_instance(mut self, input: i32) -> Self {
825        self.inner = self.inner.max_sessions_per_instance(input);
826        self
827    }
828    /// <p>The maximum number of user sessions on an instance. This only applies to multi-session fleets.</p>
829    pub fn set_max_sessions_per_instance(mut self, input: ::std::option::Option<i32>) -> Self {
830        self.inner = self.inner.set_max_sessions_per_instance(input);
831        self
832    }
833    /// <p>The maximum number of user sessions on an instance. This only applies to multi-session fleets.</p>
834    pub fn get_max_sessions_per_instance(&self) -> &::std::option::Option<i32> {
835        self.inner.get_max_sessions_per_instance()
836    }
837    /// <p>The configuration for the root volume of fleet instances. Use this to customize storage capacity from 200 GB up to 500 GB based on your application requirements.</p>
838    pub fn root_volume_config(mut self, input: crate::types::VolumeConfig) -> Self {
839        self.inner = self.inner.root_volume_config(input);
840        self
841    }
842    /// <p>The configuration for the root volume of fleet instances. Use this to customize storage capacity from 200 GB up to 500 GB based on your application requirements.</p>
843    pub fn set_root_volume_config(mut self, input: ::std::option::Option<crate::types::VolumeConfig>) -> Self {
844        self.inner = self.inner.set_root_volume_config(input);
845        self
846    }
847    /// <p>The configuration for the root volume of fleet instances. Use this to customize storage capacity from 200 GB up to 500 GB based on your application requirements.</p>
848    pub fn get_root_volume_config(&self) -> &::std::option::Option<crate::types::VolumeConfig> {
849        self.inner.get_root_volume_config()
850    }
851}