checkMatchingParent static method
Ensure that node
has a matching parent.
Implementation
static void checkMatchingParent(XmlParentable node, XmlNode parent) {
if (node.parent != parent) {
// If this exception is ever thrown, this is likely a bug in the internal
// code of the library.
throw XmlParentException('Node already has a non-matching parent: $node');
}
}