78 78 | "com.amazonaws.ec2.synthetic",
|
79 79 | "RestoreSnapshotFromRecycleBinOutput",
|
80 80 | );
|
81 81 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SNAPSHOT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
82 82 | ::aws_smithy_schema::ShapeId::from_static(
|
83 83 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$SnapshotId",
|
84 84 | "com.amazonaws.ec2.synthetic",
|
85 85 | "RestoreSnapshotFromRecycleBinOutput",
|
86 86 | ),
|
87 87 | ::aws_smithy_schema::ShapeType::String,
|
88 - | "snapshot_id",
|
88 + | "SnapshotId",
|
89 89 | 0,
|
90 90 | )
|
91 91 | .with_xml_name("snapshotId");
|
92 92 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OUTPOST_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
93 93 | ::aws_smithy_schema::ShapeId::from_static(
|
94 94 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$OutpostArn",
|
95 95 | "com.amazonaws.ec2.synthetic",
|
96 96 | "RestoreSnapshotFromRecycleBinOutput",
|
97 97 | ),
|
98 98 | ::aws_smithy_schema::ShapeType::String,
|
99 - | "outpost_arn",
|
99 + | "OutpostArn",
|
100 100 | 1,
|
101 101 | )
|
102 102 | .with_xml_name("outpostArn");
|
103 103 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_DESCRIPTION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
104 104 | ::aws_smithy_schema::ShapeId::from_static(
|
105 105 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$Description",
|
106 106 | "com.amazonaws.ec2.synthetic",
|
107 107 | "RestoreSnapshotFromRecycleBinOutput",
|
108 108 | ),
|
109 109 | ::aws_smithy_schema::ShapeType::String,
|
110 - | "description",
|
110 + | "Description",
|
111 111 | 2,
|
112 112 | )
|
113 113 | .with_xml_name("description");
|
114 114 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_ENCRYPTED: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
115 115 | ::aws_smithy_schema::ShapeId::from_static(
|
116 116 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$Encrypted",
|
117 117 | "com.amazonaws.ec2.synthetic",
|
118 118 | "RestoreSnapshotFromRecycleBinOutput",
|
119 119 | ),
|
120 120 | ::aws_smithy_schema::ShapeType::Boolean,
|
121 - | "encrypted",
|
121 + | "Encrypted",
|
122 122 | 3,
|
123 123 | )
|
124 124 | .with_xml_name("encrypted");
|
125 125 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OWNER_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
126 126 | ::aws_smithy_schema::ShapeId::from_static(
|
127 127 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$OwnerId",
|
128 128 | "com.amazonaws.ec2.synthetic",
|
129 129 | "RestoreSnapshotFromRecycleBinOutput",
|
130 130 | ),
|
131 131 | ::aws_smithy_schema::ShapeType::String,
|
132 - | "owner_id",
|
132 + | "OwnerId",
|
133 133 | 4,
|
134 134 | )
|
135 135 | .with_xml_name("ownerId");
|
136 136 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_PROGRESS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
137 137 | ::aws_smithy_schema::ShapeId::from_static(
|
138 138 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$Progress",
|
139 139 | "com.amazonaws.ec2.synthetic",
|
140 140 | "RestoreSnapshotFromRecycleBinOutput",
|
141 141 | ),
|
142 142 | ::aws_smithy_schema::ShapeType::String,
|
143 - | "progress",
|
143 + | "Progress",
|
144 144 | 5,
|
145 145 | )
|
146 146 | .with_xml_name("progress");
|
147 147 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_START_TIME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
148 148 | ::aws_smithy_schema::ShapeId::from_static(
|
149 149 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$StartTime",
|
150 150 | "com.amazonaws.ec2.synthetic",
|
151 151 | "RestoreSnapshotFromRecycleBinOutput",
|
152 152 | ),
|
153 153 | ::aws_smithy_schema::ShapeType::Timestamp,
|
154 - | "start_time",
|
154 + | "StartTime",
|
155 155 | 6,
|
156 156 | )
|
157 157 | .with_xml_name("startTime");
|
158 158 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_STATE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
159 159 | ::aws_smithy_schema::ShapeId::from_static(
|
160 160 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$State",
|
161 161 | "com.amazonaws.ec2.synthetic",
|
162 162 | "RestoreSnapshotFromRecycleBinOutput",
|
163 163 | ),
|
164 164 | ::aws_smithy_schema::ShapeType::String,
|
165 - | "state",
|
165 + | "State",
|
166 166 | 7,
|
167 167 | )
|
168 168 | .with_xml_name("status");
|
169 169 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
170 170 | ::aws_smithy_schema::ShapeId::from_static(
|
171 171 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$VolumeId",
|
172 172 | "com.amazonaws.ec2.synthetic",
|
173 173 | "RestoreSnapshotFromRecycleBinOutput",
|
174 174 | ),
|
175 175 | ::aws_smithy_schema::ShapeType::String,
|
176 - | "volume_id",
|
176 + | "VolumeId",
|
177 177 | 8,
|
178 178 | )
|
179 179 | .with_xml_name("volumeId");
|
180 180 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_SIZE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
181 181 | ::aws_smithy_schema::ShapeId::from_static(
|
182 182 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$VolumeSize",
|
183 183 | "com.amazonaws.ec2.synthetic",
|
184 184 | "RestoreSnapshotFromRecycleBinOutput",
|
185 185 | ),
|
186 186 | ::aws_smithy_schema::ShapeType::Integer,
|
187 - | "volume_size",
|
187 + | "VolumeSize",
|
188 188 | 9,
|
189 189 | )
|
190 190 | .with_xml_name("volumeSize");
|
191 191 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SSE_TYPE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
192 192 | ::aws_smithy_schema::ShapeId::from_static(
|
193 193 | "com.amazonaws.ec2.synthetic#RestoreSnapshotFromRecycleBinOutput$SseType",
|
194 194 | "com.amazonaws.ec2.synthetic",
|
195 195 | "RestoreSnapshotFromRecycleBinOutput",
|
196 196 | ),
|
197 197 | ::aws_smithy_schema::ShapeType::String,
|
198 - | "sse_type",
|
198 + | "SseType",
|
199 199 | 10,
|
200 200 | )
|
201 201 | .with_xml_name("sseType");
|
202 + | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
203 + | ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
|
204 + | ::aws_smithy_schema::ShapeType::String,
|
205 + | "request_id",
|
206 + | 11,
|
207 + | )
|
208 + | .with_http_header("x-amzn-requestid");
|
202 209 | static RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
203 210 | RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA_ID,
|
204 211 | ::aws_smithy_schema::ShapeType::Structure,
|
205 212 | &[
|
206 213 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SNAPSHOT_ID,
|
207 214 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OUTPOST_ARN,
|
208 215 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_DESCRIPTION,
|
209 216 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_ENCRYPTED,
|
210 217 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OWNER_ID,
|
211 218 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_PROGRESS,
|
212 219 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_START_TIME,
|
213 220 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_STATE,
|
214 221 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_ID,
|
215 222 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_SIZE,
|
216 223 | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SSE_TYPE,
|
224 + | &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER__REQUEST_ID,
|
217 225 | ],
|
218 226 | );
|
219 227 | impl RestoreSnapshotFromRecycleBinOutput {
|
220 228 | /// The schema for this shape.
|
221 229 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA;
|
222 230 | }
|
223 231 | impl ::aws_smithy_schema::serde::SerializableStruct for RestoreSnapshotFromRecycleBinOutput {
|
224 232 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
225 233 | fn serialize_members(
|
226 234 | &self,
|
227 235 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
228 236 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
229 237 | if let Some(ref val) = self.snapshot_id {
|
230 238 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SNAPSHOT_ID, val)?;
|
231 239 | }
|
232 240 | if let Some(ref val) = self.outpost_arn {
|
233 241 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OUTPOST_ARN, val)?;
|
234 242 | }
|
235 243 | if let Some(ref val) = self.description {
|
236 244 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_DESCRIPTION, val)?;
|
237 245 | }
|
238 246 | if let Some(ref val) = self.encrypted {
|
239 247 | ser.write_boolean(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_ENCRYPTED, *val)?;
|
240 248 | }
|
241 249 | if let Some(ref val) = self.owner_id {
|
242 250 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_OWNER_ID, val)?;
|
243 251 | }
|
244 252 | if let Some(ref val) = self.progress {
|
245 253 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_PROGRESS, val)?;
|
246 254 | }
|
247 255 | if let Some(ref val) = self.start_time {
|
248 256 | ser.write_timestamp(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_START_TIME, val)?;
|
249 257 | }
|
250 258 | if let Some(ref val) = self.state {
|
251 259 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_STATE, val.as_str())?;
|
252 260 | }
|
253 261 | if let Some(ref val) = self.volume_id {
|
254 262 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_ID, val)?;
|
255 263 | }
|
256 264 | if let Some(ref val) = self.volume_size {
|
257 265 | ser.write_integer(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_VOLUME_SIZE, *val)?;
|
258 266 | }
|
259 267 | if let Some(ref val) = self.sse_type {
|
260 268 | ser.write_string(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_MEMBER_SSE_TYPE, val.as_str())?;
|
261 269 | }
|
262 270 | Ok(())
|
263 271 | }
|
264 272 | }
|
265 273 | impl RestoreSnapshotFromRecycleBinOutput {
|
266 274 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
267 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
268 - | deserializer: &mut D,
|
275 + | pub fn deserialize(
|
276 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
277 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
278 + | #[allow(unused_variables, unused_mut)]
|
279 + | let mut builder = Self::builder();
|
280 + | #[allow(
|
281 + | unused_variables,
|
282 + | unreachable_code,
|
283 + | clippy::single_match,
|
284 + | clippy::match_single_binding,
|
285 + | clippy::diverging_sub_expression
|
286 + | )]
|
287 + | deserializer.read_struct(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA, &mut |member, deser| {
|
288 + | match member.member_index() {
|
289 + | Some(0) => {
|
290 + | builder.snapshot_id = Some(deser.read_string(member)?);
|
291 + | }
|
292 + | Some(1) => {
|
293 + | builder.outpost_arn = Some(deser.read_string(member)?);
|
294 + | }
|
295 + | Some(2) => {
|
296 + | builder.description = Some(deser.read_string(member)?);
|
297 + | }
|
298 + | Some(3) => {
|
299 + | builder.encrypted = Some(deser.read_boolean(member)?);
|
300 + | }
|
301 + | Some(4) => {
|
302 + | builder.owner_id = Some(deser.read_string(member)?);
|
303 + | }
|
304 + | Some(5) => {
|
305 + | builder.progress = Some(deser.read_string(member)?);
|
306 + | }
|
307 + | Some(6) => {
|
308 + | builder.start_time = Some(deser.read_timestamp(member)?);
|
309 + | }
|
310 + | Some(7) => {
|
311 + | builder.state = Some(crate::types::SnapshotState::from(deser.read_string(member)?.as_str()));
|
312 + | }
|
313 + | Some(8) => {
|
314 + | builder.volume_id = Some(deser.read_string(member)?);
|
315 + | }
|
316 + | Some(9) => {
|
317 + | builder.volume_size = Some(deser.read_integer(member)?);
|
318 + | }
|
319 + | Some(10) => {
|
320 + | builder.sse_type = Some(crate::types::SseType::from(deser.read_string(member)?.as_str()));
|
321 + | }
|
322 + | Some(11) => {
|
323 + | builder._request_id = Some(deser.read_string(member)?);
|
324 + | }
|
325 + | _ => {}
|
326 + | }
|
327 + | Ok(())
|
328 + | })?;
|
329 + | Ok(builder.build())
|
330 + | }
|
331 + | }
|
332 + | impl RestoreSnapshotFromRecycleBinOutput {
|
333 + | /// Deserializes this structure from a body deserializer and HTTP response headers.
|
334 + | /// Header-bound members are read directly from headers, avoiding runtime
|
335 + | /// member iteration overhead. Body members are read via the deserializer.
|
336 + | pub fn deserialize_with_response(
|
337 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
338 + | headers: &::aws_smithy_runtime_api::http::Headers,
|
339 + | _status: u16,
|
340 + | _body: &[u8],
|
269 341 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
270 342 | #[allow(unused_variables, unused_mut)]
|
271 343 | let mut builder = Self::builder();
|
344 + | if let Some(val) = headers.get("x-amzn-requestid") {
|
345 + | builder._request_id = Some(val.to_string());
|
346 + | }
|
272 347 | #[allow(
|
273 348 | unused_variables,
|
274 349 | unreachable_code,
|
275 350 | clippy::single_match,
|
276 351 | clippy::match_single_binding,
|
277 352 | clippy::diverging_sub_expression
|
278 353 | )]
|
279 - | deserializer.read_struct(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA, (), |_, member, deser| {
|
354 + | deserializer.read_struct(&RESTORESNAPSHOTFROMRECYCLEBINOUTPUT_SCHEMA, &mut |member, deser| {
|
280 355 | match member.member_index() {
|
281 356 | Some(0) => {
|
282 357 | builder.snapshot_id = Some(deser.read_string(member)?);
|
283 358 | }
|
284 359 | Some(1) => {
|
285 360 | builder.outpost_arn = Some(deser.read_string(member)?);
|
286 361 | }
|
287 362 | Some(2) => {
|
288 363 | builder.description = Some(deser.read_string(member)?);
|
289 364 | }
|