CdmDocument.dup

CdmDocument dup() const pure @safe

Creates a deep copy of this document.

All nodes and comments are recursively copied.

Acyclicity precondition: the document's node graph must be acyclic. Cycles through raw member/attribute pointers are not detected by the recursive copy.

Returns

An independent copy of this document.