Struct aws_sdk_ec2::model::Vpc
source · #[non_exhaustive]pub struct Vpc { /* private fields */ }
Expand description
Describes a VPC.
Implementations§
source§impl Vpc
impl Vpc
sourcepub fn cidr_block(&self) -> Option<&str>
pub fn cidr_block(&self) -> Option<&str>
The primary IPv4 CIDR block for the VPC.
sourcepub fn dhcp_options_id(&self) -> Option<&str>
pub fn dhcp_options_id(&self) -> Option<&str>
The ID of the set of DHCP options you've associated with the VPC.
sourcepub fn owner_id(&self) -> Option<&str>
pub fn owner_id(&self) -> Option<&str>
The ID of the Amazon Web Services account that owns the VPC.
sourcepub fn instance_tenancy(&self) -> Option<&Tenancy>
pub fn instance_tenancy(&self) -> Option<&Tenancy>
The allowed tenancy of instances launched into the VPC.
sourcepub fn ipv6_cidr_block_association_set(
&self
) -> Option<&[VpcIpv6CidrBlockAssociation]>
pub fn ipv6_cidr_block_association_set(
&self
) -> Option<&[VpcIpv6CidrBlockAssociation]>
Information about the IPv6 CIDR blocks associated with the VPC.
sourcepub fn cidr_block_association_set(&self) -> Option<&[VpcCidrBlockAssociation]>
pub fn cidr_block_association_set(&self) -> Option<&[VpcCidrBlockAssociation]>
Information about the IPv4 CIDR blocks associated with the VPC.
sourcepub fn is_default(&self) -> Option<bool>
pub fn is_default(&self) -> Option<bool>
Indicates whether the VPC is the default VPC.
Any tags assigned to the VPC.
source§impl Vpc
impl Vpc
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture Vpc
.
Examples found in repository?
src/xml_deser.rs (line 26665)
26661 26662 26663 26664 26665 26666 26667 26668 26669 26670 26671 26672 26673 26674 26675 26676 26677 26678 26679 26680 26681 26682 26683 26684 26685 26686 26687 26688 26689 26690 26691 26692 26693 26694 26695 26696 26697 26698 26699 26700 26701 26702 26703 26704 26705 26706 26707 26708 26709 26710 26711 26712 26713 26714 26715 26716 26717 26718 26719 26720 26721 26722 26723 26724 26725 26726 26727 26728 26729 26730 26731 26732 26733 26734 26735 26736 26737 26738 26739 26740 26741 26742 26743 26744 26745 26746 26747 26748 26749 26750 26751 26752 26753 26754 26755 26756 26757 26758 26759 26760 26761 26762 26763 26764 26765 26766 26767 26768 26769 26770 26771 26772 26773 26774 26775 26776 26777 26778 26779 26780 26781 26782 26783 26784 26785 26786 26787 26788 26789 26790 26791 26792 26793 26794 26795 26796 26797
pub fn deser_structure_crate_model_vpc(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::Vpc, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::Vpc::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("cidrBlock") /* CidrBlock com.amazonaws.ec2#Vpc$CidrBlock */ => {
let var_1061 =
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_cidr_block(var_1061);
}
,
s if s.matches("dhcpOptionsId") /* DhcpOptionsId com.amazonaws.ec2#Vpc$DhcpOptionsId */ => {
let var_1062 =
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_dhcp_options_id(var_1062);
}
,
s if s.matches("state") /* State com.amazonaws.ec2#Vpc$State */ => {
let var_1063 =
Some(
Result::<crate::model::VpcState, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::VpcState::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_state(var_1063);
}
,
s if s.matches("vpcId") /* VpcId com.amazonaws.ec2#Vpc$VpcId */ => {
let var_1064 =
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_vpc_id(var_1064);
}
,
s if s.matches("ownerId") /* OwnerId com.amazonaws.ec2#Vpc$OwnerId */ => {
let var_1065 =
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_owner_id(var_1065);
}
,
s if s.matches("instanceTenancy") /* InstanceTenancy com.amazonaws.ec2#Vpc$InstanceTenancy */ => {
let var_1066 =
Some(
Result::<crate::model::Tenancy, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::Tenancy::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_instance_tenancy(var_1066);
}
,
s if s.matches("ipv6CidrBlockAssociationSet") /* Ipv6CidrBlockAssociationSet com.amazonaws.ec2#Vpc$Ipv6CidrBlockAssociationSet */ => {
let var_1067 =
Some(
crate::xml_deser::deser_list_com_amazonaws_ec2_vpc_ipv6_cidr_block_association_set(&mut tag)
?
)
;
builder = builder.set_ipv6_cidr_block_association_set(var_1067);
}
,
s if s.matches("cidrBlockAssociationSet") /* CidrBlockAssociationSet com.amazonaws.ec2#Vpc$CidrBlockAssociationSet */ => {
let var_1068 =
Some(
crate::xml_deser::deser_list_com_amazonaws_ec2_vpc_cidr_block_association_set(&mut tag)
?
)
;
builder = builder.set_cidr_block_association_set(var_1068);
}
,
s if s.matches("isDefault") /* IsDefault com.amazonaws.ec2#Vpc$IsDefault */ => {
let var_1069 =
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_is_default(var_1069);
}
,
s if s.matches("tagSet") /* Tags com.amazonaws.ec2#Vpc$Tags */ => {
let var_1070 =
Some(
crate::xml_deser::deser_list_com_amazonaws_ec2_tag_list(&mut tag)
?
)
;
builder = builder.set_tags(var_1070);
}
,
_ => {}
}
}
Ok(builder.build())
}