60 60 | "com.amazonaws.ec2.synthetic",
|
61 61 | "AllocateAddressOutput",
|
62 62 | );
|
63 63 | static ALLOCATEADDRESSOUTPUT_MEMBER_ALLOCATION_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
64 64 | ::aws_smithy_schema::ShapeId::from_static(
|
65 65 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$AllocationId",
|
66 66 | "com.amazonaws.ec2.synthetic",
|
67 67 | "AllocateAddressOutput",
|
68 68 | ),
|
69 69 | ::aws_smithy_schema::ShapeType::String,
|
70 - | "allocation_id",
|
70 + | "AllocationId",
|
71 71 | 0,
|
72 72 | )
|
73 73 | .with_xml_name("allocationId");
|
74 74 | static ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IPV4_POOL: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
75 75 | ::aws_smithy_schema::ShapeId::from_static(
|
76 76 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$PublicIpv4Pool",
|
77 77 | "com.amazonaws.ec2.synthetic",
|
78 78 | "AllocateAddressOutput",
|
79 79 | ),
|
80 80 | ::aws_smithy_schema::ShapeType::String,
|
81 - | "public_ipv4_pool",
|
81 + | "PublicIpv4Pool",
|
82 82 | 1,
|
83 83 | )
|
84 84 | .with_xml_name("publicIpv4Pool");
|
85 85 | static ALLOCATEADDRESSOUTPUT_MEMBER_NETWORK_BORDER_GROUP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
86 86 | ::aws_smithy_schema::ShapeId::from_static(
|
87 87 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$NetworkBorderGroup",
|
88 88 | "com.amazonaws.ec2.synthetic",
|
89 89 | "AllocateAddressOutput",
|
90 90 | ),
|
91 91 | ::aws_smithy_schema::ShapeType::String,
|
92 - | "network_border_group",
|
92 + | "NetworkBorderGroup",
|
93 93 | 2,
|
94 94 | )
|
95 95 | .with_xml_name("networkBorderGroup");
|
96 96 | static ALLOCATEADDRESSOUTPUT_MEMBER_DOMAIN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
97 97 | ::aws_smithy_schema::ShapeId::from_static(
|
98 98 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$Domain",
|
99 99 | "com.amazonaws.ec2.synthetic",
|
100 100 | "AllocateAddressOutput",
|
101 101 | ),
|
102 102 | ::aws_smithy_schema::ShapeType::String,
|
103 - | "domain",
|
103 + | "Domain",
|
104 104 | 3,
|
105 105 | )
|
106 106 | .with_xml_name("domain");
|
107 107 | static ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
108 108 | ::aws_smithy_schema::ShapeId::from_static(
|
109 109 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$CustomerOwnedIp",
|
110 110 | "com.amazonaws.ec2.synthetic",
|
111 111 | "AllocateAddressOutput",
|
112 112 | ),
|
113 113 | ::aws_smithy_schema::ShapeType::String,
|
114 - | "customer_owned_ip",
|
114 + | "CustomerOwnedIp",
|
115 115 | 4,
|
116 116 | )
|
117 117 | .with_xml_name("customerOwnedIp");
|
118 118 | static ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IPV4_POOL: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
119 119 | ::aws_smithy_schema::ShapeId::from_static(
|
120 120 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$CustomerOwnedIpv4Pool",
|
121 121 | "com.amazonaws.ec2.synthetic",
|
122 122 | "AllocateAddressOutput",
|
123 123 | ),
|
124 124 | ::aws_smithy_schema::ShapeType::String,
|
125 - | "customer_owned_ipv4_pool",
|
125 + | "CustomerOwnedIpv4Pool",
|
126 126 | 5,
|
127 127 | )
|
128 128 | .with_xml_name("customerOwnedIpv4Pool");
|
129 129 | static ALLOCATEADDRESSOUTPUT_MEMBER_CARRIER_IP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
130 130 | ::aws_smithy_schema::ShapeId::from_static(
|
131 131 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$CarrierIp",
|
132 132 | "com.amazonaws.ec2.synthetic",
|
133 133 | "AllocateAddressOutput",
|
134 134 | ),
|
135 135 | ::aws_smithy_schema::ShapeType::String,
|
136 - | "carrier_ip",
|
136 + | "CarrierIp",
|
137 137 | 6,
|
138 138 | )
|
139 139 | .with_xml_name("carrierIp");
|
140 140 | static ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
141 141 | ::aws_smithy_schema::ShapeId::from_static(
|
142 142 | "com.amazonaws.ec2.synthetic#AllocateAddressOutput$PublicIp",
|
143 143 | "com.amazonaws.ec2.synthetic",
|
144 144 | "AllocateAddressOutput",
|
145 145 | ),
|
146 146 | ::aws_smithy_schema::ShapeType::String,
|
147 - | "public_ip",
|
147 + | "PublicIp",
|
148 148 | 7,
|
149 149 | )
|
150 150 | .with_xml_name("publicIp");
|
151 + | static ALLOCATEADDRESSOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
152 + | ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
|
153 + | ::aws_smithy_schema::ShapeType::String,
|
154 + | "request_id",
|
155 + | 8,
|
156 + | )
|
157 + | .with_http_header("x-amzn-requestid");
|
151 158 | static ALLOCATEADDRESSOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
152 159 | ALLOCATEADDRESSOUTPUT_SCHEMA_ID,
|
153 160 | ::aws_smithy_schema::ShapeType::Structure,
|
154 161 | &[
|
155 162 | &ALLOCATEADDRESSOUTPUT_MEMBER_ALLOCATION_ID,
|
156 163 | &ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IPV4_POOL,
|
157 164 | &ALLOCATEADDRESSOUTPUT_MEMBER_NETWORK_BORDER_GROUP,
|
158 165 | &ALLOCATEADDRESSOUTPUT_MEMBER_DOMAIN,
|
159 166 | &ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IP,
|
160 167 | &ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IPV4_POOL,
|
161 168 | &ALLOCATEADDRESSOUTPUT_MEMBER_CARRIER_IP,
|
162 169 | &ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IP,
|
170 + | &ALLOCATEADDRESSOUTPUT_MEMBER__REQUEST_ID,
|
163 171 | ],
|
164 172 | );
|
165 173 | impl AllocateAddressOutput {
|
166 174 | /// The schema for this shape.
|
167 175 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &ALLOCATEADDRESSOUTPUT_SCHEMA;
|
168 176 | }
|
169 177 | impl ::aws_smithy_schema::serde::SerializableStruct for AllocateAddressOutput {
|
170 178 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
171 179 | fn serialize_members(
|
172 180 | &self,
|
173 181 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
174 182 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
175 183 | if let Some(ref val) = self.allocation_id {
|
176 184 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_ALLOCATION_ID, val)?;
|
177 185 | }
|
178 186 | if let Some(ref val) = self.public_ipv4_pool {
|
179 187 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IPV4_POOL, val)?;
|
180 188 | }
|
181 189 | if let Some(ref val) = self.network_border_group {
|
182 190 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_NETWORK_BORDER_GROUP, val)?;
|
183 191 | }
|
184 192 | if let Some(ref val) = self.domain {
|
185 193 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_DOMAIN, val.as_str())?;
|
186 194 | }
|
187 195 | if let Some(ref val) = self.customer_owned_ip {
|
188 196 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IP, val)?;
|
189 197 | }
|
190 198 | if let Some(ref val) = self.customer_owned_ipv4_pool {
|
191 199 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_CUSTOMER_OWNED_IPV4_POOL, val)?;
|
192 200 | }
|
193 201 | if let Some(ref val) = self.carrier_ip {
|
194 202 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_CARRIER_IP, val)?;
|
195 203 | }
|
196 204 | if let Some(ref val) = self.public_ip {
|
197 205 | ser.write_string(&ALLOCATEADDRESSOUTPUT_MEMBER_PUBLIC_IP, val)?;
|
198 206 | }
|
199 207 | Ok(())
|
200 208 | }
|
201 209 | }
|
202 210 | impl AllocateAddressOutput {
|
203 211 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
204 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
205 - | deserializer: &mut D,
|
212 + | pub fn deserialize(
|
213 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
206 214 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
207 215 | #[allow(unused_variables, unused_mut)]
|
208 216 | let mut builder = Self::builder();
|
209 217 | #[allow(
|
210 218 | unused_variables,
|
211 219 | unreachable_code,
|
212 220 | clippy::single_match,
|
213 221 | clippy::match_single_binding,
|
214 222 | clippy::diverging_sub_expression
|
215 223 | )]
|
216 - | deserializer.read_struct(&ALLOCATEADDRESSOUTPUT_SCHEMA, (), |_, member, deser| {
|
224 + | deserializer.read_struct(&ALLOCATEADDRESSOUTPUT_SCHEMA, &mut |member, deser| {
|
225 + | match member.member_index() {
|
226 + | Some(0) => {
|
227 + | builder.allocation_id = Some(deser.read_string(member)?);
|
228 + | }
|
229 + | Some(1) => {
|
230 + | builder.public_ipv4_pool = Some(deser.read_string(member)?);
|
231 + | }
|
232 + | Some(2) => {
|
233 + | builder.network_border_group = Some(deser.read_string(member)?);
|
234 + | }
|
235 + | Some(3) => {
|
236 + | builder.domain = Some(crate::types::DomainType::from(deser.read_string(member)?.as_str()));
|
237 + | }
|
238 + | Some(4) => {
|
239 + | builder.customer_owned_ip = Some(deser.read_string(member)?);
|
240 + | }
|
241 + | Some(5) => {
|
242 + | builder.customer_owned_ipv4_pool = Some(deser.read_string(member)?);
|
243 + | }
|
244 + | Some(6) => {
|
245 + | builder.carrier_ip = Some(deser.read_string(member)?);
|
246 + | }
|
247 + | Some(7) => {
|
248 + | builder.public_ip = Some(deser.read_string(member)?);
|
249 + | }
|
250 + | Some(8) => {
|
251 + | builder._request_id = Some(deser.read_string(member)?);
|
252 + | }
|
253 + | _ => {}
|
254 + | }
|
255 + | Ok(())
|
256 + | })?;
|
257 + | Ok(builder.build())
|
258 + | }
|
259 + | }
|
260 + | impl AllocateAddressOutput {
|
261 + | /// Deserializes this structure from a body deserializer and HTTP response headers.
|
262 + | /// Header-bound members are read directly from headers, avoiding runtime
|
263 + | /// member iteration overhead. Body members are read via the deserializer.
|
264 + | pub fn deserialize_with_response(
|
265 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
266 + | headers: &::aws_smithy_runtime_api::http::Headers,
|
267 + | _status: u16,
|
268 + | _body: &[u8],
|
269 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
270 + | #[allow(unused_variables, unused_mut)]
|
271 + | let mut builder = Self::builder();
|
272 + | if let Some(val) = headers.get("x-amzn-requestid") {
|
273 + | builder._request_id = Some(val.to_string());
|
274 + | }
|
275 + | #[allow(
|
276 + | unused_variables,
|
277 + | unreachable_code,
|
278 + | clippy::single_match,
|
279 + | clippy::match_single_binding,
|
280 + | clippy::diverging_sub_expression
|
281 + | )]
|
282 + | deserializer.read_struct(&ALLOCATEADDRESSOUTPUT_SCHEMA, &mut |member, deser| {
|
217 283 | match member.member_index() {
|
218 284 | Some(0) => {
|
219 285 | builder.allocation_id = Some(deser.read_string(member)?);
|
220 286 | }
|
221 287 | Some(1) => {
|
222 288 | builder.public_ipv4_pool = Some(deser.read_string(member)?);
|
223 289 | }
|
224 290 | Some(2) => {
|
225 291 | builder.network_border_group = Some(deser.read_string(member)?);
|
226 292 | }
|