121 121 | /// <p>The attribute of the JobDescriptor containing details about the job's generated manifest.</p>
|
122 122 | pub fn generated_manifest_descriptor(&self) -> ::std::option::Option<&crate::types::S3GeneratedManifestDescriptor> {
|
123 123 | self.generated_manifest_descriptor.as_ref()
|
124 124 | }
|
125 125 | }
|
126 126 | static JOBDESCRIPTOR_SCHEMA_ID: ::aws_smithy_schema::ShapeId =
|
127 127 | ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.s3control#JobDescriptor", "com.amazonaws.s3control", "JobDescriptor");
|
128 128 | static JOBDESCRIPTOR_MEMBER_JOB_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
129 129 | ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.s3control#JobDescriptor$JobId", "com.amazonaws.s3control", "JobDescriptor"),
|
130 130 | ::aws_smithy_schema::ShapeType::String,
|
131 - | "job_id",
|
131 + | "JobId",
|
132 132 | 0,
|
133 133 | );
|
134 134 | static JOBDESCRIPTOR_MEMBER_CONFIRMATION_REQUIRED: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
135 135 | ::aws_smithy_schema::ShapeId::from_static(
|
136 136 | "com.amazonaws.s3control#JobDescriptor$ConfirmationRequired",
|
137 137 | "com.amazonaws.s3control",
|
138 138 | "JobDescriptor",
|
139 139 | ),
|
140 140 | ::aws_smithy_schema::ShapeType::Boolean,
|
141 - | "confirmation_required",
|
141 + | "ConfirmationRequired",
|
142 142 | 1,
|
143 143 | );
|
144 144 | static JOBDESCRIPTOR_MEMBER_DESCRIPTION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
145 145 | ::aws_smithy_schema::ShapeId::from_static(
|
146 146 | "com.amazonaws.s3control#JobDescriptor$Description",
|
147 147 | "com.amazonaws.s3control",
|
148 148 | "JobDescriptor",
|
149 149 | ),
|
150 150 | ::aws_smithy_schema::ShapeType::String,
|
151 - | "description",
|
151 + | "Description",
|
152 152 | 2,
|
153 153 | );
|
154 154 | static JOBDESCRIPTOR_MEMBER_JOB_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
155 155 | ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.s3control#JobDescriptor$JobArn", "com.amazonaws.s3control", "JobDescriptor"),
|
156 156 | ::aws_smithy_schema::ShapeType::String,
|
157 - | "job_arn",
|
157 + | "JobArn",
|
158 158 | 3,
|
159 159 | );
|
160 160 | static JOBDESCRIPTOR_MEMBER_STATUS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
161 161 | ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.s3control#JobDescriptor$Status", "com.amazonaws.s3control", "JobDescriptor"),
|
162 162 | ::aws_smithy_schema::ShapeType::String,
|
163 - | "status",
|
163 + | "Status",
|
164 164 | 4,
|
165 165 | );
|
166 166 | static JOBDESCRIPTOR_MEMBER_MANIFEST: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
167 167 | ::aws_smithy_schema::ShapeId::from_static(
|
168 168 | "com.amazonaws.s3control#JobDescriptor$Manifest",
|
169 169 | "com.amazonaws.s3control",
|
170 170 | "JobDescriptor",
|
171 171 | ),
|
172 172 | ::aws_smithy_schema::ShapeType::Structure,
|
173 - | "manifest",
|
173 + | "Manifest",
|
174 174 | 5,
|
175 175 | );
|
176 176 | static JOBDESCRIPTOR_MEMBER_OPERATION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
177 177 | ::aws_smithy_schema::ShapeId::from_static(
|
178 178 | "com.amazonaws.s3control#JobDescriptor$Operation",
|
179 179 | "com.amazonaws.s3control",
|
180 180 | "JobDescriptor",
|
181 181 | ),
|
182 182 | ::aws_smithy_schema::ShapeType::Structure,
|
183 - | "operation",
|
183 + | "Operation",
|
184 184 | 6,
|
185 185 | );
|
186 186 | static JOBDESCRIPTOR_MEMBER_PRIORITY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
187 187 | ::aws_smithy_schema::ShapeId::from_static(
|
188 188 | "com.amazonaws.s3control#JobDescriptor$Priority",
|
189 189 | "com.amazonaws.s3control",
|
190 190 | "JobDescriptor",
|
191 191 | ),
|
192 192 | ::aws_smithy_schema::ShapeType::Integer,
|
193 - | "priority",
|
193 + | "Priority",
|
194 194 | 7,
|
195 195 | );
|
196 196 | static JOBDESCRIPTOR_MEMBER_PROGRESS_SUMMARY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
197 197 | ::aws_smithy_schema::ShapeId::from_static(
|
198 198 | "com.amazonaws.s3control#JobDescriptor$ProgressSummary",
|
199 199 | "com.amazonaws.s3control",
|
200 200 | "JobDescriptor",
|
201 201 | ),
|
202 202 | ::aws_smithy_schema::ShapeType::Structure,
|
203 - | "progress_summary",
|
203 + | "ProgressSummary",
|
204 204 | 8,
|
205 205 | );
|
206 206 | static JOBDESCRIPTOR_MEMBER_STATUS_UPDATE_REASON: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
207 207 | ::aws_smithy_schema::ShapeId::from_static(
|
208 208 | "com.amazonaws.s3control#JobDescriptor$StatusUpdateReason",
|
209 209 | "com.amazonaws.s3control",
|
210 210 | "JobDescriptor",
|
211 211 | ),
|
212 212 | ::aws_smithy_schema::ShapeType::String,
|
213 - | "status_update_reason",
|
213 + | "StatusUpdateReason",
|
214 214 | 9,
|
215 215 | );
|
216 216 | static JOBDESCRIPTOR_MEMBER_FAILURE_REASONS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
217 217 | ::aws_smithy_schema::ShapeId::from_static(
|
218 218 | "com.amazonaws.s3control#JobDescriptor$FailureReasons",
|
219 219 | "com.amazonaws.s3control",
|
220 220 | "JobDescriptor",
|
221 221 | ),
|
222 222 | ::aws_smithy_schema::ShapeType::List,
|
223 - | "failure_reasons",
|
223 + | "FailureReasons",
|
224 224 | 10,
|
225 225 | );
|
226 226 | static JOBDESCRIPTOR_MEMBER_REPORT: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
227 227 | ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.s3control#JobDescriptor$Report", "com.amazonaws.s3control", "JobDescriptor"),
|
228 228 | ::aws_smithy_schema::ShapeType::Structure,
|
229 - | "report",
|
229 + | "Report",
|
230 230 | 11,
|
231 231 | );
|
232 232 | static JOBDESCRIPTOR_MEMBER_CREATION_TIME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
233 233 | ::aws_smithy_schema::ShapeId::from_static(
|
234 234 | "com.amazonaws.s3control#JobDescriptor$CreationTime",
|
235 235 | "com.amazonaws.s3control",
|
236 236 | "JobDescriptor",
|
237 237 | ),
|
238 238 | ::aws_smithy_schema::ShapeType::Timestamp,
|
239 - | "creation_time",
|
239 + | "CreationTime",
|
240 240 | 12,
|
241 241 | );
|
242 242 | static JOBDESCRIPTOR_MEMBER_TERMINATION_DATE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
243 243 | ::aws_smithy_schema::ShapeId::from_static(
|
244 244 | "com.amazonaws.s3control#JobDescriptor$TerminationDate",
|
245 245 | "com.amazonaws.s3control",
|
246 246 | "JobDescriptor",
|
247 247 | ),
|
248 248 | ::aws_smithy_schema::ShapeType::Timestamp,
|
249 - | "termination_date",
|
249 + | "TerminationDate",
|
250 250 | 13,
|
251 251 | );
|
252 252 | static JOBDESCRIPTOR_MEMBER_ROLE_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
253 253 | ::aws_smithy_schema::ShapeId::from_static(
|
254 254 | "com.amazonaws.s3control#JobDescriptor$RoleArn",
|
255 255 | "com.amazonaws.s3control",
|
256 256 | "JobDescriptor",
|
257 257 | ),
|
258 258 | ::aws_smithy_schema::ShapeType::String,
|
259 - | "role_arn",
|
259 + | "RoleArn",
|
260 260 | 14,
|
261 261 | );
|
262 262 | static JOBDESCRIPTOR_MEMBER_SUSPENDED_DATE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
263 263 | ::aws_smithy_schema::ShapeId::from_static(
|
264 264 | "com.amazonaws.s3control#JobDescriptor$SuspendedDate",
|
265 265 | "com.amazonaws.s3control",
|
266 266 | "JobDescriptor",
|
267 267 | ),
|
268 268 | ::aws_smithy_schema::ShapeType::Timestamp,
|
269 - | "suspended_date",
|
269 + | "SuspendedDate",
|
270 270 | 15,
|
271 271 | );
|
272 272 | static JOBDESCRIPTOR_MEMBER_SUSPENDED_CAUSE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
273 273 | ::aws_smithy_schema::ShapeId::from_static(
|
274 274 | "com.amazonaws.s3control#JobDescriptor$SuspendedCause",
|
275 275 | "com.amazonaws.s3control",
|
276 276 | "JobDescriptor",
|
277 277 | ),
|
278 278 | ::aws_smithy_schema::ShapeType::String,
|
279 - | "suspended_cause",
|
279 + | "SuspendedCause",
|
280 280 | 16,
|
281 281 | );
|
282 282 | static JOBDESCRIPTOR_MEMBER_MANIFEST_GENERATOR: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
283 283 | ::aws_smithy_schema::ShapeId::from_static(
|
284 284 | "com.amazonaws.s3control#JobDescriptor$ManifestGenerator",
|
285 285 | "com.amazonaws.s3control",
|
286 286 | "JobDescriptor",
|
287 287 | ),
|
288 288 | ::aws_smithy_schema::ShapeType::Union,
|
289 - | "manifest_generator",
|
289 + | "ManifestGenerator",
|
290 290 | 17,
|
291 291 | );
|
292 292 | static JOBDESCRIPTOR_MEMBER_GENERATED_MANIFEST_DESCRIPTOR: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
293 293 | ::aws_smithy_schema::ShapeId::from_static(
|
294 294 | "com.amazonaws.s3control#JobDescriptor$GeneratedManifestDescriptor",
|
295 295 | "com.amazonaws.s3control",
|
296 296 | "JobDescriptor",
|
297 297 | ),
|
298 298 | ::aws_smithy_schema::ShapeType::Structure,
|
299 - | "generated_manifest_descriptor",
|
299 + | "GeneratedManifestDescriptor",
|
300 300 | 18,
|
301 301 | );
|
302 302 | static JOBDESCRIPTOR_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
303 303 | JOBDESCRIPTOR_SCHEMA_ID,
|
304 304 | ::aws_smithy_schema::ShapeType::Structure,
|
305 305 | &[
|
306 306 | &JOBDESCRIPTOR_MEMBER_JOB_ID,
|
307 307 | &JOBDESCRIPTOR_MEMBER_CONFIRMATION_REQUIRED,
|
308 308 | &JOBDESCRIPTOR_MEMBER_DESCRIPTION,
|
309 309 | &JOBDESCRIPTOR_MEMBER_JOB_ARN,
|
388 388 | if let Some(ref val) = self.role_arn {
|
389 389 | ser.write_string(&JOBDESCRIPTOR_MEMBER_ROLE_ARN, val)?;
|
390 390 | }
|
391 391 | if let Some(ref val) = self.suspended_date {
|
392 392 | ser.write_timestamp(&JOBDESCRIPTOR_MEMBER_SUSPENDED_DATE, val)?;
|
393 393 | }
|
394 394 | if let Some(ref val) = self.suspended_cause {
|
395 395 | ser.write_string(&JOBDESCRIPTOR_MEMBER_SUSPENDED_CAUSE, val)?;
|
396 396 | }
|
397 397 | if let Some(ref val) = self.manifest_generator {
|
398 - | ser.write_null(&JOBDESCRIPTOR_MEMBER_MANIFEST_GENERATOR)?;
|
398 + | ser.write_struct(&JOBDESCRIPTOR_MEMBER_MANIFEST_GENERATOR, val)?;
|
399 399 | }
|
400 400 | if let Some(ref val) = self.generated_manifest_descriptor {
|
401 401 | ser.write_struct(&JOBDESCRIPTOR_MEMBER_GENERATED_MANIFEST_DESCRIPTOR, val)?;
|
402 402 | }
|
403 403 | Ok(())
|
404 404 | }
|
405 405 | }
|
406 406 | impl JobDescriptor {
|
407 407 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
408 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
409 - | deserializer: &mut D,
|
408 + | pub fn deserialize(
|
409 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
410 410 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
411 411 | #[allow(unused_variables, unused_mut)]
|
412 412 | let mut builder = Self::builder();
|
413 413 | #[allow(
|
414 414 | unused_variables,
|
415 415 | unreachable_code,
|
416 416 | clippy::single_match,
|
417 417 | clippy::match_single_binding,
|
418 418 | clippy::diverging_sub_expression
|
419 419 | )]
|
420 - | deserializer.read_struct(&JOBDESCRIPTOR_SCHEMA, (), |_, member, deser| {
|
420 + | deserializer.read_struct(&JOBDESCRIPTOR_SCHEMA, &mut |member, deser| {
|
421 421 | match member.member_index() {
|
422 422 | Some(0) => {
|
423 423 | builder.job_id = Some(deser.read_string(member)?);
|
424 424 | }
|
425 425 | Some(1) => {
|
426 426 | builder.confirmation_required = Some(deser.read_boolean(member)?);
|
427 427 | }
|
428 428 | Some(2) => {
|
429 429 | builder.description = Some(deser.read_string(member)?);
|
430 430 | }
|
431 431 | Some(3) => {
|
432 432 | builder.job_arn = Some(deser.read_string(member)?);
|
433 433 | }
|
434 434 | Some(4) => {
|
435 435 | builder.status = Some(crate::types::JobStatus::from(deser.read_string(member)?.as_str()));
|
436 436 | }
|
437 437 | Some(5) => {
|
438 438 | builder.manifest = Some(crate::types::JobManifest::deserialize(deser)?);
|
439 439 | }
|
440 440 | Some(6) => {
|
441 441 | builder.operation = Some(crate::types::JobOperation::deserialize(deser)?);
|
442 442 | }
|
443 443 | Some(7) => {
|
444 444 | builder.priority = Some(deser.read_integer(member)?);
|
445 445 | }
|
446 446 | Some(8) => {
|
447 447 | builder.progress_summary = Some(crate::types::JobProgressSummary::deserialize(deser)?);
|
448 448 | }
|
449 449 | Some(9) => {
|
450 450 | builder.status_update_reason = Some(deser.read_string(member)?);
|
451 451 | }
|
452 452 | Some(10) => {
|
453 453 | builder.failure_reasons = Some({
|
454 - | let container = if let Some(cap) = deser.container_size() {
|
455 - | Vec::with_capacity(cap)
|
456 - | } else {
|
457 - | Vec::new()
|
458 - | };
|
459 - | deser.read_list(member, container, |mut list, deser| {
|
460 - | list.push(crate::types::JobFailure::deserialize(deser)?);
|
461 - | Ok(list)
|
462 - | })?
|
454 + | let mut container = Vec::new();
|
455 + | deser.read_list(member, &mut |deser| {
|
456 + | container.push(crate::types::JobFailure::deserialize(deser)?);
|
457 + | Ok(())
|
458 + | })?;
|
459 + | container
|
463 460 | });
|
464 461 | }
|
465 462 | Some(11) => {
|
466 463 | builder.report = Some(crate::types::JobReport::deserialize(deser)?);
|
467 464 | }
|
468 465 | Some(12) => {
|
469 466 | builder.creation_time = Some(deser.read_timestamp(member)?);
|
470 467 | }
|
471 468 | Some(13) => {
|
472 469 | builder.termination_date = Some(deser.read_timestamp(member)?);
|
473 470 | }
|
474 471 | Some(14) => {
|
475 472 | builder.role_arn = Some(deser.read_string(member)?);
|
476 473 | }
|
477 474 | Some(15) => {
|
478 475 | builder.suspended_date = Some(deser.read_timestamp(member)?);
|
479 476 | }
|
480 477 | Some(16) => {
|
481 478 | builder.suspended_cause = Some(deser.read_string(member)?);
|
482 479 | }
|
483 480 | Some(17) => {
|
484 - | builder.manifest_generator = Some({
|
485 - | let _ = member;
|
486 - | todo!("deserialize aggregate")
|
487 - | });
|
481 + | builder.manifest_generator = Some(crate::types::JobManifestGenerator::deserialize(deser)?);
|
488 482 | }
|
489 483 | Some(18) => {
|
490 484 | builder.generated_manifest_descriptor = Some(crate::types::S3GeneratedManifestDescriptor::deserialize(deser)?);
|
491 485 | }
|
492 486 | _ => {}
|
493 487 | }
|
494 488 | Ok(())
|
495 489 | })?;
|
496 490 | Ok(builder.build())
|
497 491 | }
|
498 492 | }
|
493 + | impl JobDescriptor {
|
494 + | /// Deserializes this structure from a body deserializer and HTTP response.
|
495 + | pub fn deserialize_with_response(
|
496 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
497 + | _headers: &::aws_smithy_runtime_api::http::Headers,
|
498 + | _status: u16,
|
499 + | _body: &[u8],
|
500 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
501 + | Self::deserialize(deserializer)
|
502 + | }
|
503 + | }
|
499 504 | impl JobDescriptor {
|
500 505 | /// Creates a new builder-style object to manufacture [`JobDescriptor`](crate::types::JobDescriptor).
|
501 506 | pub fn builder() -> crate::types::builders::JobDescriptorBuilder {
|
502 507 | crate::types::builders::JobDescriptorBuilder::default()
|
503 508 | }
|
504 509 | }
|
505 510 |
|
506 511 | /// A builder for [`JobDescriptor`](crate::types::JobDescriptor).
|
507 512 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
508 513 | #[non_exhaustive]
|
509 514 | pub struct JobDescriptorBuilder {
|
510 515 | pub(crate) job_id: ::std::option::Option<::std::string::String>,
|
511 516 | pub(crate) confirmation_required: ::std::option::Option<bool>,
|
512 517 | pub(crate) description: ::std::option::Option<::std::string::String>,
|
513 518 | pub(crate) job_arn: ::std::option::Option<::std::string::String>,
|
514 519 | pub(crate) status: ::std::option::Option<crate::types::JobStatus>,
|
515 520 | pub(crate) manifest: ::std::option::Option<crate::types::JobManifest>,
|
516 521 | pub(crate) operation: ::std::option::Option<crate::types::JobOperation>,
|
517 522 | pub(crate) priority: ::std::option::Option<i32>,
|
518 523 | pub(crate) progress_summary: ::std::option::Option<crate::types::JobProgressSummary>,
|
519 524 | pub(crate) status_update_reason: ::std::option::Option<::std::string::String>,
|
520 525 | pub(crate) failure_reasons: ::std::option::Option<::std::vec::Vec<crate::types::JobFailure>>,
|
521 526 | pub(crate) report: ::std::option::Option<crate::types::JobReport>,
|
522 527 | pub(crate) creation_time: ::std::option::Option<::aws_smithy_types::DateTime>,
|
523 528 | pub(crate) termination_date: ::std::option::Option<::aws_smithy_types::DateTime>,
|
524 529 | pub(crate) role_arn: ::std::option::Option<::std::string::String>,
|
525 530 | pub(crate) suspended_date: ::std::option::Option<::aws_smithy_types::DateTime>,
|
526 531 | pub(crate) suspended_cause: ::std::option::Option<::std::string::String>,
|
527 532 | pub(crate) manifest_generator: ::std::option::Option<crate::types::JobManifestGenerator>,
|
528 533 | pub(crate) generated_manifest_descriptor: ::std::option::Option<crate::types::S3GeneratedManifestDescriptor>,
|