XmlElement constructor

XmlElement(
  1. XmlName name,
  2. [Iterable<XmlAttribute> attributesIterable = const [],
  3. Iterable<XmlNode> childrenIterable = const [],
  4. bool isSelfClosing = true]
)

Create an element node with the provided name, attributes, and children.

Implementation

XmlElement(this.name,
    [Iterable<XmlAttribute> attributesIterable = const [],
    Iterable<XmlNode> childrenIterable = const [],
    this.isSelfClosing = true]) {
  name.attachParent(this);
  attributes.initialize(this, attributeNodeTypes);
  attributes.addAll(attributesIterable);
  children.initialize(this, childrenNodeTypes);
  children.addAll(childrenIterable);
}