toXml method

XmlElement toXml(
  1. String elemName, {
  2. List<XmlAttribute>? attributes,
})

Implementation

_s.XmlElement toXml(String elemName, {List<_s.XmlAttribute>? attributes}) {
  final accountId = this.accountId;
  final bucket = this.bucket;
  final name = this.name;
  final publicAccessBlockConfiguration = this.publicAccessBlockConfiguration;
  final vpcConfiguration = this.vpcConfiguration;
  final $children = <_s.XmlNode>[
    _s.encodeXmlStringValue('Bucket', bucket),
    if (vpcConfiguration != null) vpcConfiguration.toXml('VpcConfiguration'),
    if (publicAccessBlockConfiguration != null)
      publicAccessBlockConfiguration.toXml('PublicAccessBlockConfiguration'),
  ];
  final $attributes = <_s.XmlAttribute>[
    ...?attributes,
  ];
  return _s.XmlElement(
    _s.XmlName(elemName),
    $attributes,
    $children,
  );
}