Xml.XMLDoc.TXMLNode.Create

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

constructor Create(const ADOMNode: IDOMNode; const AParentNode: TXMLNode;
const OwnerDoc: TXMLDocument);

C++

__fastcall TXMLNode(const Xml::Xmldom::_di_IDOMNode ADOMNode, TXMLNode* const AParentNode, TXMLDocument* const OwnerDoc);
__fastcall TXMLNode(TXMLNode* HostNode);

Properties

Type Visibility Source Unit Parent
constructor public
Xml.XMLDoc.pas
Xml.XMLDoc.hpp
Xml.XMLDoc TXMLNode

Description

Instantiates a Create object.

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.

See Also