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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
// 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 UpdateProxyInput {
/// <p>The NAT Gateway the proxy is attached to.</p>
pub nat_gateway_id: ::std::option::Option<::std::string::String>,
/// <p>The descriptive name of the proxy. You can't change the name of a proxy after you create it.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub proxy_name: ::std::option::Option<::std::string::String>,
/// <p>The Amazon Resource Name (ARN) of a proxy.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub proxy_arn: ::std::option::Option<::std::string::String>,
/// <p>Listener properties for HTTP and HTTPS traffic to add.</p>
pub listener_properties_to_add: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>,
/// <p>Listener properties for HTTP and HTTPS traffic to remove.</p>
pub listener_properties_to_remove: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>,
/// <p>TLS decryption on traffic to filter on attributes in the HTTP header.</p>
pub tls_intercept_properties: ::std::option::Option<crate::types::TlsInterceptPropertiesRequest>,
/// <p>A token used for optimistic locking. Network Firewall returns a token to your requests that access the proxy. The token marks the state of the proxy resource at the time of the request.</p>
/// <p>To make changes to the proxy, you provide the token in your request. Network Firewall uses the token to ensure that the proxy hasn't changed since you last retrieved it. If it has changed, the operation fails with an <code>InvalidTokenException</code>. If this happens, retrieve the proxy again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.</p>
pub update_token: ::std::option::Option<::std::string::String>,
}
impl UpdateProxyInput {
/// <p>The NAT Gateway the proxy is attached to.</p>
pub fn nat_gateway_id(&self) -> ::std::option::Option<&str> {
self.nat_gateway_id.as_deref()
}
/// <p>The descriptive name of the proxy. You can't change the name of a proxy after you create it.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn proxy_name(&self) -> ::std::option::Option<&str> {
self.proxy_name.as_deref()
}
/// <p>The Amazon Resource Name (ARN) of a proxy.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn proxy_arn(&self) -> ::std::option::Option<&str> {
self.proxy_arn.as_deref()
}
/// <p>Listener properties for HTTP and HTTPS traffic to add.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.listener_properties_to_add.is_none()`.
pub fn listener_properties_to_add(&self) -> &[crate::types::ListenerPropertyRequest] {
self.listener_properties_to_add.as_deref().unwrap_or_default()
}
/// <p>Listener properties for HTTP and HTTPS traffic to remove.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.listener_properties_to_remove.is_none()`.
pub fn listener_properties_to_remove(&self) -> &[crate::types::ListenerPropertyRequest] {
self.listener_properties_to_remove.as_deref().unwrap_or_default()
}
/// <p>TLS decryption on traffic to filter on attributes in the HTTP header.</p>
pub fn tls_intercept_properties(&self) -> ::std::option::Option<&crate::types::TlsInterceptPropertiesRequest> {
self.tls_intercept_properties.as_ref()
}
/// <p>A token used for optimistic locking. Network Firewall returns a token to your requests that access the proxy. The token marks the state of the proxy resource at the time of the request.</p>
/// <p>To make changes to the proxy, you provide the token in your request. Network Firewall uses the token to ensure that the proxy hasn't changed since you last retrieved it. If it has changed, the operation fails with an <code>InvalidTokenException</code>. If this happens, retrieve the proxy again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.</p>
pub fn update_token(&self) -> ::std::option::Option<&str> {
self.update_token.as_deref()
}
}
impl UpdateProxyInput {
/// Creates a new builder-style object to manufacture [`UpdateProxyInput`](crate::operation::update_proxy::UpdateProxyInput).
pub fn builder() -> crate::operation::update_proxy::builders::UpdateProxyInputBuilder {
crate::operation::update_proxy::builders::UpdateProxyInputBuilder::default()
}
}
/// A builder for [`UpdateProxyInput`](crate::operation::update_proxy::UpdateProxyInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateProxyInputBuilder {
pub(crate) nat_gateway_id: ::std::option::Option<::std::string::String>,
pub(crate) proxy_name: ::std::option::Option<::std::string::String>,
pub(crate) proxy_arn: ::std::option::Option<::std::string::String>,
pub(crate) listener_properties_to_add: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>,
pub(crate) listener_properties_to_remove: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>,
pub(crate) tls_intercept_properties: ::std::option::Option<crate::types::TlsInterceptPropertiesRequest>,
pub(crate) update_token: ::std::option::Option<::std::string::String>,
}
impl UpdateProxyInputBuilder {
/// <p>The NAT Gateway the proxy is attached to.</p>
/// This field is required.
pub fn nat_gateway_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.nat_gateway_id = ::std::option::Option::Some(input.into());
self
}
/// <p>The NAT Gateway the proxy is attached to.</p>
pub fn set_nat_gateway_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.nat_gateway_id = input;
self
}
/// <p>The NAT Gateway the proxy is attached to.</p>
pub fn get_nat_gateway_id(&self) -> &::std::option::Option<::std::string::String> {
&self.nat_gateway_id
}
/// <p>The descriptive name of the proxy. You can't change the name of a proxy after you create it.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn proxy_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.proxy_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The descriptive name of the proxy. You can't change the name of a proxy after you create it.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn set_proxy_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.proxy_name = input;
self
}
/// <p>The descriptive name of the proxy. You can't change the name of a proxy after you create it.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn get_proxy_name(&self) -> &::std::option::Option<::std::string::String> {
&self.proxy_name
}
/// <p>The Amazon Resource Name (ARN) of a proxy.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn proxy_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.proxy_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of a proxy.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn set_proxy_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.proxy_arn = input;
self
}
/// <p>The Amazon Resource Name (ARN) of a proxy.</p>
/// <p>You must specify the ARN or the name, and you can specify both.</p>
pub fn get_proxy_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.proxy_arn
}
/// Appends an item to `listener_properties_to_add`.
///
/// To override the contents of this collection use [`set_listener_properties_to_add`](Self::set_listener_properties_to_add).
///
/// <p>Listener properties for HTTP and HTTPS traffic to add.</p>
pub fn listener_properties_to_add(mut self, input: crate::types::ListenerPropertyRequest) -> Self {
let mut v = self.listener_properties_to_add.unwrap_or_default();
v.push(input);
self.listener_properties_to_add = ::std::option::Option::Some(v);
self
}
/// <p>Listener properties for HTTP and HTTPS traffic to add.</p>
pub fn set_listener_properties_to_add(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>) -> Self {
self.listener_properties_to_add = input;
self
}
/// <p>Listener properties for HTTP and HTTPS traffic to add.</p>
pub fn get_listener_properties_to_add(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>> {
&self.listener_properties_to_add
}
/// Appends an item to `listener_properties_to_remove`.
///
/// To override the contents of this collection use [`set_listener_properties_to_remove`](Self::set_listener_properties_to_remove).
///
/// <p>Listener properties for HTTP and HTTPS traffic to remove.</p>
pub fn listener_properties_to_remove(mut self, input: crate::types::ListenerPropertyRequest) -> Self {
let mut v = self.listener_properties_to_remove.unwrap_or_default();
v.push(input);
self.listener_properties_to_remove = ::std::option::Option::Some(v);
self
}
/// <p>Listener properties for HTTP and HTTPS traffic to remove.</p>
pub fn set_listener_properties_to_remove(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>>) -> Self {
self.listener_properties_to_remove = input;
self
}
/// <p>Listener properties for HTTP and HTTPS traffic to remove.</p>
pub fn get_listener_properties_to_remove(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ListenerPropertyRequest>> {
&self.listener_properties_to_remove
}
/// <p>TLS decryption on traffic to filter on attributes in the HTTP header.</p>
pub fn tls_intercept_properties(mut self, input: crate::types::TlsInterceptPropertiesRequest) -> Self {
self.tls_intercept_properties = ::std::option::Option::Some(input);
self
}
/// <p>TLS decryption on traffic to filter on attributes in the HTTP header.</p>
pub fn set_tls_intercept_properties(mut self, input: ::std::option::Option<crate::types::TlsInterceptPropertiesRequest>) -> Self {
self.tls_intercept_properties = input;
self
}
/// <p>TLS decryption on traffic to filter on attributes in the HTTP header.</p>
pub fn get_tls_intercept_properties(&self) -> &::std::option::Option<crate::types::TlsInterceptPropertiesRequest> {
&self.tls_intercept_properties
}
/// <p>A token used for optimistic locking. Network Firewall returns a token to your requests that access the proxy. The token marks the state of the proxy resource at the time of the request.</p>
/// <p>To make changes to the proxy, you provide the token in your request. Network Firewall uses the token to ensure that the proxy hasn't changed since you last retrieved it. If it has changed, the operation fails with an <code>InvalidTokenException</code>. If this happens, retrieve the proxy again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.</p>
/// This field is required.
pub fn update_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.update_token = ::std::option::Option::Some(input.into());
self
}
/// <p>A token used for optimistic locking. Network Firewall returns a token to your requests that access the proxy. The token marks the state of the proxy resource at the time of the request.</p>
/// <p>To make changes to the proxy, you provide the token in your request. Network Firewall uses the token to ensure that the proxy hasn't changed since you last retrieved it. If it has changed, the operation fails with an <code>InvalidTokenException</code>. If this happens, retrieve the proxy again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.</p>
pub fn set_update_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.update_token = input;
self
}
/// <p>A token used for optimistic locking. Network Firewall returns a token to your requests that access the proxy. The token marks the state of the proxy resource at the time of the request.</p>
/// <p>To make changes to the proxy, you provide the token in your request. Network Firewall uses the token to ensure that the proxy hasn't changed since you last retrieved it. If it has changed, the operation fails with an <code>InvalidTokenException</code>. If this happens, retrieve the proxy again to get a current copy of it with a current token. Reapply your changes as needed, then try the operation again using the new token.</p>
pub fn get_update_token(&self) -> &::std::option::Option<::std::string::String> {
&self.update_token
}
/// Consumes the builder and constructs a [`UpdateProxyInput`](crate::operation::update_proxy::UpdateProxyInput).
pub fn build(self) -> ::std::result::Result<crate::operation::update_proxy::UpdateProxyInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_proxy::UpdateProxyInput {
nat_gateway_id: self.nat_gateway_id,
proxy_name: self.proxy_name,
proxy_arn: self.proxy_arn,
listener_properties_to_add: self.listener_properties_to_add,
listener_properties_to_remove: self.listener_properties_to_remove,
tls_intercept_properties: self.tls_intercept_properties,
update_token: self.update_token,
})
}
}