Struct aws_sdk_ec2::model::PublicIpv4PoolRange
source · #[non_exhaustive]pub struct PublicIpv4PoolRange { /* private fields */ }
Expand description
Describes an address range of an IPv4 address pool.
Implementations§
source§impl PublicIpv4PoolRange
impl PublicIpv4PoolRange
sourcepub fn first_address(&self) -> Option<&str>
pub fn first_address(&self) -> Option<&str>
The first IP address in the range.
sourcepub fn last_address(&self) -> Option<&str>
pub fn last_address(&self) -> Option<&str>
The last IP address in the range.
sourcepub fn address_count(&self) -> Option<i32>
pub fn address_count(&self) -> Option<i32>
The number of addresses in the range.
sourcepub fn available_address_count(&self) -> Option<i32>
pub fn available_address_count(&self) -> Option<i32>
The number of available addresses in the range.
source§impl PublicIpv4PoolRange
impl PublicIpv4PoolRange
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture PublicIpv4PoolRange
.
Examples found in repository?
src/xml_deser.rs (line 38154)
38150 38151 38152 38153 38154 38155 38156 38157 38158 38159 38160 38161 38162 38163 38164 38165 38166 38167 38168 38169 38170 38171 38172 38173 38174 38175 38176 38177 38178 38179 38180 38181 38182 38183 38184 38185 38186 38187 38188 38189 38190 38191 38192 38193 38194 38195 38196 38197 38198 38199 38200 38201 38202 38203 38204 38205 38206 38207 38208 38209 38210 38211 38212 38213 38214 38215 38216 38217
pub fn deser_structure_crate_model_public_ipv4_pool_range(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::PublicIpv4PoolRange, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::PublicIpv4PoolRange::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("firstAddress") /* FirstAddress com.amazonaws.ec2#PublicIpv4PoolRange$FirstAddress */ => {
let var_1605 =
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_first_address(var_1605);
}
,
s if s.matches("lastAddress") /* LastAddress com.amazonaws.ec2#PublicIpv4PoolRange$LastAddress */ => {
let var_1606 =
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_last_address(var_1606);
}
,
s if s.matches("addressCount") /* AddressCount com.amazonaws.ec2#PublicIpv4PoolRange$AddressCount */ => {
let var_1607 =
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_address_count(var_1607);
}
,
s if s.matches("availableAddressCount") /* AvailableAddressCount com.amazonaws.ec2#PublicIpv4PoolRange$AvailableAddressCount */ => {
let var_1608 =
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_available_address_count(var_1608);
}
,
_ => {}
}
}
Ok(builder.build())
}
Trait Implementations§
source§impl Clone for PublicIpv4PoolRange
impl Clone for PublicIpv4PoolRange
source§fn clone(&self) -> PublicIpv4PoolRange
fn clone(&self) -> PublicIpv4PoolRange
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