Object.fromXml constructor

Object.fromXml(
  1. XmlElement xml
)

Implementation

Object.fromXml(XmlElement xml) {
  eTag = getProp(xml, 'ETag')?.innerText;
  key = getProp(xml, 'Key')?.innerText;
  lastModified = DateTime.parse(getProp(xml, 'LastModified')!.innerText);
  owner = Owner.fromXml(getProp(xml, 'Owner'));
  size = int.tryParse(getProp(xml, 'Size')!.innerText);
  storageClass = getProp(xml, 'StorageClass')?.innerText;
}