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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// A request to update the cluster.
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateClusterInput {
/// The ID of the cluster
pub cluster_id: ::std::option::Option<::std::string::String>,
/// Include this parameter only if you want to change the current name of the Cluster. Specify a name that is unique in the AWS account. You can't change the name. Names are case-sensitive.
pub name: ::std::option::Option<::std::string::String>,
/// Include this property only if you want to change the current connections between the Nodes in the Cluster and the Networks the Cluster is associated with.
pub network_settings: ::std::option::Option<crate::types::ClusterNetworkSettingsUpdateRequest>,
}
impl UpdateClusterInput {
/// The ID of the cluster
pub fn cluster_id(&self) -> ::std::option::Option<&str> {
self.cluster_id.as_deref()
}
/// Include this parameter only if you want to change the current name of the Cluster. Specify a name that is unique in the AWS account. You can't change the name. Names are case-sensitive.
pub fn name(&self) -> ::std::option::Option<&str> {
self.name.as_deref()
}
/// Include this property only if you want to change the current connections between the Nodes in the Cluster and the Networks the Cluster is associated with.
pub fn network_settings(&self) -> ::std::option::Option<&crate::types::ClusterNetworkSettingsUpdateRequest> {
self.network_settings.as_ref()
}
}
impl UpdateClusterInput {
/// Creates a new builder-style object to manufacture [`UpdateClusterInput`](crate::operation::update_cluster::UpdateClusterInput).
pub fn builder() -> crate::operation::update_cluster::builders::UpdateClusterInputBuilder {
crate::operation::update_cluster::builders::UpdateClusterInputBuilder::default()
}
}
/// A builder for [`UpdateClusterInput`](crate::operation::update_cluster::UpdateClusterInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateClusterInputBuilder {
pub(crate) cluster_id: ::std::option::Option<::std::string::String>,
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) network_settings: ::std::option::Option<crate::types::ClusterNetworkSettingsUpdateRequest>,
}
impl UpdateClusterInputBuilder {
/// The ID of the cluster
/// This field is required.
pub fn cluster_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.cluster_id = ::std::option::Option::Some(input.into());
self
}
/// The ID of the cluster
pub fn set_cluster_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.cluster_id = input;
self
}
/// The ID of the cluster
pub fn get_cluster_id(&self) -> &::std::option::Option<::std::string::String> {
&self.cluster_id
}
/// Include this parameter only if you want to change the current name of the Cluster. Specify a name that is unique in the AWS account. You can't change the name. Names are case-sensitive.
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::Some(input.into());
self
}
/// Include this parameter only if you want to change the current name of the Cluster. Specify a name that is unique in the AWS account. You can't change the name. Names are case-sensitive.
pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.name = input;
self
}
/// Include this parameter only if you want to change the current name of the Cluster. Specify a name that is unique in the AWS account. You can't change the name. Names are case-sensitive.
pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
&self.name
}
/// Include this property only if you want to change the current connections between the Nodes in the Cluster and the Networks the Cluster is associated with.
pub fn network_settings(mut self, input: crate::types::ClusterNetworkSettingsUpdateRequest) -> Self {
self.network_settings = ::std::option::Option::Some(input);
self
}
/// Include this property only if you want to change the current connections between the Nodes in the Cluster and the Networks the Cluster is associated with.
pub fn set_network_settings(mut self, input: ::std::option::Option<crate::types::ClusterNetworkSettingsUpdateRequest>) -> Self {
self.network_settings = input;
self
}
/// Include this property only if you want to change the current connections between the Nodes in the Cluster and the Networks the Cluster is associated with.
pub fn get_network_settings(&self) -> &::std::option::Option<crate::types::ClusterNetworkSettingsUpdateRequest> {
&self.network_settings
}
/// Consumes the builder and constructs a [`UpdateClusterInput`](crate::operation::update_cluster::UpdateClusterInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_cluster::UpdateClusterInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_cluster::UpdateClusterInput {
cluster_id: self.cluster_id,
name: self.name,
network_settings: self.network_settings,
})
}
}