Struct aws_sdk_ec2::model::StoreImageTaskResult
source · #[non_exhaustive]pub struct StoreImageTaskResult { /* private fields */ }
Expand description
The information about the AMI store task, including the progress of the task.
Implementations§
source§impl StoreImageTaskResult
impl StoreImageTaskResult
sourcepub fn task_start_time(&self) -> Option<&DateTime>
pub fn task_start_time(&self) -> Option<&DateTime>
The time the task started.
sourcepub fn bucket(&self) -> Option<&str>
pub fn bucket(&self) -> Option<&str>
The name of the Amazon S3 bucket that contains the stored AMI object.
sourcepub fn s3object_key(&self) -> Option<&str>
pub fn s3object_key(&self) -> Option<&str>
The name of the stored AMI object in the bucket.
sourcepub fn progress_percentage(&self) -> Option<i32>
pub fn progress_percentage(&self) -> Option<i32>
The progress of the task as a percentage.
sourcepub fn store_task_state(&self) -> Option<&str>
pub fn store_task_state(&self) -> Option<&str>
The state of the store task (InProgress
, Completed
, or Failed
).
sourcepub fn store_task_failure_reason(&self) -> Option<&str>
pub fn store_task_failure_reason(&self) -> Option<&str>
If the tasks fails, the reason for the failure is returned. If the task succeeds, null
is returned.
source§impl StoreImageTaskResult
impl StoreImageTaskResult
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture StoreImageTaskResult
.
Examples found in repository?
src/xml_deser.rs (line 50494)
50490 50491 50492 50493 50494 50495 50496 50497 50498 50499 50500 50501 50502 50503 50504 50505 50506 50507 50508 50509 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 50521 50522 50523 50524 50525 50526 50527 50528 50529 50530 50531 50532 50533 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 50552 50553 50554 50555 50556 50557 50558 50559 50560 50561 50562 50563 50564 50565 50566 50567 50568 50569 50570 50571 50572 50573 50574 50575 50576 50577 50578 50579 50580 50581 50582 50583 50584 50585 50586 50587 50588 50589 50590 50591 50592 50593 50594 50595
pub fn deser_structure_crate_model_store_image_task_result(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::StoreImageTaskResult, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::StoreImageTaskResult::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("amiId") /* AmiId com.amazonaws.ec2#StoreImageTaskResult$AmiId */ => {
let var_2373 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_ami_id(var_2373);
}
,
s if s.matches("taskStartTime") /* TaskStartTime com.amazonaws.ec2#StoreImageTaskResult$TaskStartTime */ => {
let var_2374 =
Some(
aws_smithy_types::DateTime::from_str(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
, aws_smithy_types::date_time::Format::DateTime
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (timestamp: `com.amazonaws.ec2#MillisecondDateTime`)"))
?
)
;
builder = builder.set_task_start_time(var_2374);
}
,
s if s.matches("bucket") /* Bucket com.amazonaws.ec2#StoreImageTaskResult$Bucket */ => {
let var_2375 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_bucket(var_2375);
}
,
s if s.matches("s3objectKey") /* S3objectKey com.amazonaws.ec2#StoreImageTaskResult$S3objectKey */ => {
let var_2376 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_s3object_key(var_2376);
}
,
s if s.matches("progressPercentage") /* ProgressPercentage com.amazonaws.ec2#StoreImageTaskResult$ProgressPercentage */ => {
let var_2377 =
Some(
{
<i32 as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (integer: `com.amazonaws.ec2#Integer`)"))
}
?
)
;
builder = builder.set_progress_percentage(var_2377);
}
,
s if s.matches("storeTaskState") /* StoreTaskState com.amazonaws.ec2#StoreImageTaskResult$StoreTaskState */ => {
let var_2378 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_store_task_state(var_2378);
}
,
s if s.matches("storeTaskFailureReason") /* StoreTaskFailureReason com.amazonaws.ec2#StoreImageTaskResult$StoreTaskFailureReason */ => {
let var_2379 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_store_task_failure_reason(var_2379);
}
,
_ => {}
}
}
Ok(builder.build())
}
Trait Implementations§
source§impl Clone for StoreImageTaskResult
impl Clone for StoreImageTaskResult
source§fn clone(&self) -> StoreImageTaskResult
fn clone(&self) -> StoreImageTaskResult
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more