Struct aws_sdk_ec2::model::SpotPlacement
source · #[non_exhaustive]pub struct SpotPlacement { /* private fields */ }
Expand description
Describes Spot Instance placement.
Implementations§
source§impl SpotPlacement
impl SpotPlacement
sourcepub fn availability_zone(&self) -> Option<&str>
pub fn availability_zone(&self) -> Option<&str>
The Availability Zone.
[Spot Fleet only] To specify multiple Availability Zones, separate them using commas; for example, "us-west-2a, us-west-2b".
sourcepub fn group_name(&self) -> Option<&str>
pub fn group_name(&self) -> Option<&str>
The name of the placement group.
source§impl SpotPlacement
impl SpotPlacement
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture SpotPlacement
.
Examples found in repository?
src/xml_deser.rs (line 66010)
66006 66007 66008 66009 66010 66011 66012 66013 66014 66015 66016 66017 66018 66019 66020 66021 66022 66023 66024 66025 66026 66027 66028 66029 66030 66031 66032 66033 66034 66035 66036 66037 66038 66039 66040 66041 66042 66043 66044 66045 66046 66047 66048 66049 66050 66051 66052 66053 66054 66055 66056 66057
pub fn deser_structure_crate_model_spot_placement(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::SpotPlacement, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::SpotPlacement::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("availabilityZone") /* AvailabilityZone com.amazonaws.ec2#SpotPlacement$AvailabilityZone */ => {
let var_3242 =
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_availability_zone(var_3242);
}
,
s if s.matches("groupName") /* GroupName com.amazonaws.ec2#SpotPlacement$GroupName */ => {
let var_3243 =
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_group_name(var_3243);
}
,
s if s.matches("tenancy") /* Tenancy com.amazonaws.ec2#SpotPlacement$Tenancy */ => {
let var_3244 =
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_tenancy(var_3244);
}
,
_ => {}
}
}
Ok(builder.build())
}
Trait Implementations§
source§impl Clone for SpotPlacement
impl Clone for SpotPlacement
source§fn clone(&self) -> SpotPlacement
fn clone(&self) -> SpotPlacement
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