TutXmlClone make an identical copy of an XML object
xml_obj
XML object to clone
Copy of the original XML object if successful; NULL
otherwise.
If TipcMsgClone fails, it returns NULL
and sets the global SmartSockets error number to:
TutXmlClone makes a copy of an existing XML object. The copied XML object does not share any memory with the original XML object.
Destroy the XML object returned by TutXmlClone when it is no longer needed by calling TutXmlDestroy.
This example creates a new XML object, then makes a copy of that XML object:
T_STR xml_str = "<data><data1><temp=\"hot\"/></data1>" "<data2><temp=\"cold\"/></data2></data>"; T_XML xml; T_XML xml_copy; xml = TutXmlCreate(xml_str); if (xml == NULL) {/* error */
} xml_copy = TutXmlClone(xml); if (xml_copy == NULL) {/* error */
}
TIBCO SmartSockets™ Utilities Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |