MetricDataResult.fromXml constructor
MetricDataResult.fromXml(
- XmlElement elem
Implementation
factory MetricDataResult.fromXml(_s.XmlElement elem) {
return MetricDataResult(
id: _s.extractXmlStringValue(elem, 'Id'),
label: _s.extractXmlStringValue(elem, 'Label'),
messages: _s.extractXmlChild(elem, 'Messages')?.let((elem) => elem
.findElements('member')
.map((c) => MessageData.fromXml(c))
.toList()),
statusCode: _s.extractXmlStringValue(elem, 'StatusCode')?.toStatusCode(),
timestamps: _s
.extractXmlChild(elem, 'Timestamps')
?.let((elem) => _s.extractXmlDateTimeListValues(elem, 'member')),
values: _s
.extractXmlChild(elem, 'Values')
?.let((elem) => _s.extractXmlDoubleListValues(elem, 'member')),
);
}