pub struct Builder { /* private fields */ }
Expand description
A builder for InstanceNetworkInterfaceAttachment
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn attach_time(self, input: DateTime) -> Self
pub fn attach_time(self, input: DateTime) -> Self
The time stamp when the attachment initiated.
sourcepub fn set_attach_time(self, input: Option<DateTime>) -> Self
pub fn set_attach_time(self, input: Option<DateTime>) -> Self
The time stamp when the attachment initiated.
Examples found in repository?
src/xml_deser.rs (line 70297)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn attachment_id(self, input: impl Into<String>) -> Self
pub fn attachment_id(self, input: impl Into<String>) -> Self
The ID of the network interface attachment.
sourcepub fn set_attachment_id(self, input: Option<String>) -> Self
pub fn set_attachment_id(self, input: Option<String>) -> Self
The ID of the network interface attachment.
Examples found in repository?
src/xml_deser.rs (line 70310)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn delete_on_termination(self, input: bool) -> Self
pub fn delete_on_termination(self, input: bool) -> Self
Indicates whether the network interface is deleted when the instance is terminated.
sourcepub fn set_delete_on_termination(self, input: Option<bool>) -> Self
pub fn set_delete_on_termination(self, input: Option<bool>) -> Self
Indicates whether the network interface is deleted when the instance is terminated.
Examples found in repository?
src/xml_deser.rs (line 70325)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn device_index(self, input: i32) -> Self
pub fn device_index(self, input: i32) -> Self
The index of the device on the instance for the network interface attachment.
sourcepub fn set_device_index(self, input: Option<i32>) -> Self
pub fn set_device_index(self, input: Option<i32>) -> Self
The index of the device on the instance for the network interface attachment.
Examples found in repository?
src/xml_deser.rs (line 70340)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn status(self, input: AttachmentStatus) -> Self
pub fn status(self, input: AttachmentStatus) -> Self
The attachment state.
sourcepub fn set_status(self, input: Option<AttachmentStatus>) -> Self
pub fn set_status(self, input: Option<AttachmentStatus>) -> Self
The attachment state.
Examples found in repository?
src/xml_deser.rs (line 70354)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn network_card_index(self, input: i32) -> Self
pub fn network_card_index(self, input: i32) -> Self
The index of the network card.
sourcepub fn set_network_card_index(self, input: Option<i32>) -> Self
pub fn set_network_card_index(self, input: Option<i32>) -> Self
The index of the network card.
Examples found in repository?
src/xml_deser.rs (line 70369)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn build(self) -> InstanceNetworkInterfaceAttachment
pub fn build(self) -> InstanceNetworkInterfaceAttachment
Consumes the builder and constructs a InstanceNetworkInterfaceAttachment
.
Examples found in repository?
src/xml_deser.rs (line 70375)
70278 70279 70280 70281 70282 70283 70284 70285 70286 70287 70288 70289 70290 70291 70292 70293 70294 70295 70296 70297 70298 70299 70300 70301 70302 70303 70304 70305 70306 70307 70308 70309 70310 70311 70312 70313 70314 70315 70316 70317 70318 70319 70320 70321 70322 70323 70324 70325 70326 70327 70328 70329 70330 70331 70332 70333 70334 70335 70336 70337 70338 70339 70340 70341 70342 70343 70344 70345 70346 70347 70348 70349 70350 70351 70352 70353 70354 70355 70356 70357 70358 70359 70360 70361 70362 70363 70364 70365 70366 70367 70368 70369 70370 70371 70372 70373 70374 70375 70376
pub fn deser_structure_crate_model_instance_network_interface_attachment(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::InstanceNetworkInterfaceAttachment, aws_smithy_xml::decode::XmlDecodeError>
{
#[allow(unused_mut)]
let mut builder = crate::model::InstanceNetworkInterfaceAttachment::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("attachTime") /* AttachTime com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachTime */ => {
let var_3478 =
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_attach_time(var_3478);
}
,
s if s.matches("attachmentId") /* AttachmentId com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$AttachmentId */ => {
let var_3479 =
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_attachment_id(var_3479);
}
,
s if s.matches("deleteOnTermination") /* DeleteOnTermination com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeleteOnTermination */ => {
let var_3480 =
Some(
{
<bool 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 (boolean: `com.amazonaws.ec2#Boolean`)"))
}
?
)
;
builder = builder.set_delete_on_termination(var_3480);
}
,
s if s.matches("deviceIndex") /* DeviceIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$DeviceIndex */ => {
let var_3481 =
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_device_index(var_3481);
}
,
s if s.matches("status") /* Status com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$Status */ => {
let var_3482 =
Some(
Result::<crate::model::AttachmentStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::AttachmentStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_3482);
}
,
s if s.matches("networkCardIndex") /* NetworkCardIndex com.amazonaws.ec2#InstanceNetworkInterfaceAttachment$NetworkCardIndex */ => {
let var_3483 =
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_network_card_index(var_3483);
}
,
_ => {}
}
}
Ok(builder.build())
}