1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateTaskSetInput {
/// <p>The short name or full Amazon Resource Name (ARN) of the cluster that hosts the service that the task set is found in.</p>
pub cluster: ::std::option::Option<::std::string::String>,
/// <p>The short name or full Amazon Resource Name (ARN) of the service that the task set is found in.</p>
pub service: ::std::option::Option<::std::string::String>,
/// <p>The short name or full Amazon Resource Name (ARN) of the task set to update.</p>
pub task_set: ::std::option::Option<::std::string::String>,
/// <p>A floating-point percentage of the desired number of tasks to place and keep running in the task set.</p>
pub scale: ::std::option::Option<crate::types::Scale>,
}
impl UpdateTaskSetInput {
/// <p>The short name or full Amazon Resource Name (ARN) of the cluster that hosts the service that the task set is found in.</p>
pub fn cluster(&self) -> ::std::option::Option<&str> {
self.cluster.as_deref()
}
/// <p>The short name or full Amazon Resource Name (ARN) of the service that the task set is found in.</p>
pub fn service(&self) -> ::std::option::Option<&str> {
self.service.as_deref()
}
/// <p>The short name or full Amazon Resource Name (ARN) of the task set to update.</p>
pub fn task_set(&self) -> ::std::option::Option<&str> {
self.task_set.as_deref()
}
/// <p>A floating-point percentage of the desired number of tasks to place and keep running in the task set.</p>
pub fn scale(&self) -> ::std::option::Option<&crate::types::Scale> {
self.scale.as_ref()
}
}
impl UpdateTaskSetInput {
/// Creates a new builder-style object to manufacture [`UpdateTaskSetInput`](crate::operation::update_task_set::UpdateTaskSetInput).
pub fn builder() -> crate::operation::update_task_set::builders::UpdateTaskSetInputBuilder {
crate::operation::update_task_set::builders::UpdateTaskSetInputBuilder::default()
}
}
/// A builder for [`UpdateTaskSetInput`](crate::operation::update_task_set::UpdateTaskSetInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateTaskSetInputBuilder {
pub(crate) cluster: ::std::option::Option<::std::string::String>,
pub(crate) service: ::std::option::Option<::std::string::String>,
pub(crate) task_set: ::std::option::Option<::std::string::String>,
pub(crate) scale: ::std::option::Option<crate::types::Scale>,
}
impl UpdateTaskSetInputBuilder {
/// <p>The short name or full Amazon Resource Name (ARN) of the cluster that hosts the service that the task set is found in.</p>
/// This field is required.
pub fn cluster(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.cluster = ::std::option::Option::Some(input.into());
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the cluster that hosts the service that the task set is found in.</p>
pub fn set_cluster(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.cluster = input;
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the cluster that hosts the service that the task set is found in.</p>
pub fn get_cluster(&self) -> &::std::option::Option<::std::string::String> {
&self.cluster
}
/// <p>The short name or full Amazon Resource Name (ARN) of the service that the task set is found in.</p>
/// This field is required.
pub fn service(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.service = ::std::option::Option::Some(input.into());
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the service that the task set is found in.</p>
pub fn set_service(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.service = input;
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the service that the task set is found in.</p>
pub fn get_service(&self) -> &::std::option::Option<::std::string::String> {
&self.service
}
/// <p>The short name or full Amazon Resource Name (ARN) of the task set to update.</p>
/// This field is required.
pub fn task_set(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.task_set = ::std::option::Option::Some(input.into());
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the task set to update.</p>
pub fn set_task_set(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.task_set = input;
self
}
/// <p>The short name or full Amazon Resource Name (ARN) of the task set to update.</p>
pub fn get_task_set(&self) -> &::std::option::Option<::std::string::String> {
&self.task_set
}
/// <p>A floating-point percentage of the desired number of tasks to place and keep running in the task set.</p>
/// This field is required.
pub fn scale(mut self, input: crate::types::Scale) -> Self {
self.scale = ::std::option::Option::Some(input);
self
}
/// <p>A floating-point percentage of the desired number of tasks to place and keep running in the task set.</p>
pub fn set_scale(mut self, input: ::std::option::Option<crate::types::Scale>) -> Self {
self.scale = input;
self
}
/// <p>A floating-point percentage of the desired number of tasks to place and keep running in the task set.</p>
pub fn get_scale(&self) -> &::std::option::Option<crate::types::Scale> {
&self.scale
}
/// Consumes the builder and constructs a [`UpdateTaskSetInput`](crate::operation::update_task_set::UpdateTaskSetInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_task_set::UpdateTaskSetInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_task_set::UpdateTaskSetInput {
cluster: self.cluster,
service: self.service,
task_set: self.task_set,
scale: self.scale,
})
}
}