DeepCopy (XmlNode function)

From m204wiki
Revision as of 04:59, 23 January 2011 by Alex (talk | contribs)
Jump to navigation Jump to search

Copy an XmlDoc or XmlNode

This method returns an exact copy of an XmlNode method object. Since an XmlNode cannot exist without its underlying XmlDoc, an XmlNode is deep copyable only, and no Copy method exists for an XmlNode. For more information about copyability, see Copying objects.

Syntax

  %dcop = %xmlobj:DeepCopy

Syntax Terms

%dcop
An XmlDoc or XmlNode object variable to contain the deep copy of %xmlobj. %dcop does not have to be empty (?? refid=dstates.).
%xmlobj
An XmlDoc or XmlNode object expression.

Usage Notes

  • The method object (%xmlobj) may be null. The output of a copy of a null object is a null object.
  • A deepCopy copies the underlying xmlDoc and sets the output xmlNode to the node in the new xmlDoc that corresponds to the input xmlNode. The AddSubtree method performs a different kind of copy: it copies a specified XmlNode and appends it to the method object.