Struct aws_sdk_elasticache::model::RecurringCharge
source · #[non_exhaustive]pub struct RecurringCharge { /* private fields */ }
Expand description
Contains the specific price and frequency of a recurring charges for a reserved cache node, or for a reserved cache node offering.
Implementations§
source§impl RecurringCharge
impl RecurringCharge
sourcepub fn recurring_charge_amount(&self) -> f64
pub fn recurring_charge_amount(&self) -> f64
The monetary amount of the recurring charge.
sourcepub fn recurring_charge_frequency(&self) -> Option<&str>
pub fn recurring_charge_frequency(&self) -> Option<&str>
The frequency of the recurring charge.
source§impl RecurringCharge
impl RecurringCharge
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture RecurringCharge
.
Examples found in repository?
src/xml_deser.rs (line 11426)
11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461
pub fn deser_structure_crate_model_recurring_charge(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::RecurringCharge, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::RecurringCharge::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("RecurringChargeAmount") /* RecurringChargeAmount com.amazonaws.elasticache#RecurringCharge$RecurringChargeAmount */ => {
let var_489 =
Some(
{
<f64 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 (double: `com.amazonaws.elasticache#Double`)"))
}
?
)
;
builder = builder.set_recurring_charge_amount(var_489);
}
,
s if s.matches("RecurringChargeFrequency") /* RecurringChargeFrequency com.amazonaws.elasticache#RecurringCharge$RecurringChargeFrequency */ => {
let var_490 =
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_recurring_charge_frequency(var_490);
}
,
_ => {}
}
}
Ok(builder.build())
}
Trait Implementations§
source§impl Clone for RecurringCharge
impl Clone for RecurringCharge
source§fn clone(&self) -> RecurringCharge
fn clone(&self) -> RecurringCharge
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