ReservedDBInstancesOffering.fromXml constructor

ReservedDBInstancesOffering.fromXml(
  1. XmlElement elem
)

Implementation

factory ReservedDBInstancesOffering.fromXml(_s.XmlElement elem) {
  return ReservedDBInstancesOffering(
    currencyCode: _s.extractXmlStringValue(elem, 'CurrencyCode'),
    dBInstanceClass: _s.extractXmlStringValue(elem, 'DBInstanceClass'),
    duration: _s.extractXmlIntValue(elem, 'Duration'),
    fixedPrice: _s.extractXmlDoubleValue(elem, 'FixedPrice'),
    multiAZ: _s.extractXmlBoolValue(elem, 'MultiAZ'),
    offeringType: _s.extractXmlStringValue(elem, 'OfferingType'),
    productDescription: _s.extractXmlStringValue(elem, 'ProductDescription'),
    recurringCharges: _s.extractXmlChild(elem, 'RecurringCharges')?.let(
        (elem) => elem
            .findElements('RecurringCharge')
            .map((c) => RecurringCharge.fromXml(c))
            .toList()),
    reservedDBInstancesOfferingId:
        _s.extractXmlStringValue(elem, 'ReservedDBInstancesOfferingId'),
    usagePrice: _s.extractXmlDoubleValue(elem, 'UsagePrice'),
  );
}