RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TXMLNode.Create Constructor

Instantiates a Create object.

Pascal
constructor Create(const ADOMNode: IDOMNode; const AParentNode: TXMLNode; const OwnerDoc: TXMLDocument);
C++
__fastcall TXMLNode(const IDOMNode ADOMNode, const TXMLNode AParentNode, const TXMLDocument OwnerDoc);

Create instantiates a new Create object to wrap an existing DOM node implementation. Using the first syntax, 

ADOMNode is the interface for the DOM implementation of the node. 

AParentNode is the implementation of the parent node of this node. 

OwnerDoc represents the XML document in which the new node occurs. 

Using the second syntax, 

HostNode is another Create object that represents the host node of this node. In this case, this node is a "hosted" node, which means it shares the same underlying parent and DOM node as the host node, but represents a different view of the host node. For example, a node that contains some child nodes that are all of the same type creates a hosted node to represent only the set of repeating child nodes. 

Typically, applications do not directly call the Create constructor. Instead, new nodes are created automatically for an XML document as necessary when the application reads their interfaces, starting with the DocumentElement property of the TXMLDocument object. To add new nodes to a document, applications call the parent node's AddChild method. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!