Struct aws_sdk_ec2::model::instance_status_event::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for InstanceStatusEvent
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn instance_event_id(self, input: impl Into<String>) -> Self
pub fn instance_event_id(self, input: impl Into<String>) -> Self
The ID of the event.
sourcepub fn set_instance_event_id(self, input: Option<String>) -> Self
pub fn set_instance_event_id(self, input: Option<String>) -> Self
The ID of the event.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn set_code(self, input: Option<EventCode>) -> Self
pub fn set_code(self, input: Option<EventCode>) -> Self
The event code.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn description(self, input: impl Into<String>) -> Self
pub fn description(self, input: impl Into<String>) -> Self
A description of the event.
After a scheduled event is completed, it can still be described for up to a week. If the event has been completed, this description starts with the following text: [Completed].
sourcepub fn set_description(self, input: Option<String>) -> Self
pub fn set_description(self, input: Option<String>) -> Self
A description of the event.
After a scheduled event is completed, it can still be described for up to a week. If the event has been completed, this description starts with the following text: [Completed].
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn set_not_after(self, input: Option<DateTime>) -> Self
pub fn set_not_after(self, input: Option<DateTime>) -> Self
The latest scheduled end time for the event.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn not_before(self, input: DateTime) -> Self
pub fn not_before(self, input: DateTime) -> Self
The earliest scheduled start time for the event.
sourcepub fn set_not_before(self, input: Option<DateTime>) -> Self
pub fn set_not_before(self, input: Option<DateTime>) -> Self
The earliest scheduled start time for the event.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn not_before_deadline(self, input: DateTime) -> Self
pub fn not_before_deadline(self, input: DateTime) -> Self
The deadline for starting the event.
sourcepub fn set_not_before_deadline(self, input: Option<DateTime>) -> Self
pub fn set_not_before_deadline(self, input: Option<DateTime>) -> Self
The deadline for starting the event.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn build(self) -> InstanceStatusEvent
pub fn build(self) -> InstanceStatusEvent
Consumes the builder and constructs a InstanceStatusEvent
.
Examples found in repository?
37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498
pub fn deser_structure_crate_model_instance_status_event(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceStatusEvent, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::InstanceStatusEvent::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("instanceEventId") /* InstanceEventId com.amazonaws.ec2#InstanceStatusEvent$InstanceEventId */ => {
let var_1559 =
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_instance_event_id(var_1559);
}
,
s if s.matches("code") /* Code com.amazonaws.ec2#InstanceStatusEvent$Code */ => {
let var_1560 =
Some(
Result::<crate::model::EventCode, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::EventCode::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_code(var_1560);
}
,
s if s.matches("description") /* Description com.amazonaws.ec2#InstanceStatusEvent$Description */ => {
let var_1561 =
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_description(var_1561);
}
,
s if s.matches("notAfter") /* NotAfter com.amazonaws.ec2#InstanceStatusEvent$NotAfter */ => {
let var_1562 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_after(var_1562);
}
,
s if s.matches("notBefore") /* NotBefore com.amazonaws.ec2#InstanceStatusEvent$NotBefore */ => {
let var_1563 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before(var_1563);
}
,
s if s.matches("notBeforeDeadline") /* NotBeforeDeadline com.amazonaws.ec2#InstanceStatusEvent$NotBeforeDeadline */ => {
let var_1564 =
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#DateTime`)"))
?
)
;
builder = builder.set_not_before_deadline(var_1564);
}
,
_ => {}
}
}
Ok(builder.build())
}