Class to refer to XML Document nodes in the DOM
![]() | Constructors and assignment operators
| ||||||||||||||||||||||||||
![]() | Destructor
| ||||||||||||||||||||||||||
![]() | Factory methods to create new nodes for the Document
| ||||||||||||||||||||||||||
![]() | Getter functions
|
Cloning function.
Destructor.
Equality and Inequality operators.
Functions to modify the DOM Node.
newChild
before the existing child node
refChild
oldChild
with newChild
in the list of children, and returns the oldChild
node
oldChild
from the list
of children, and returns it
newChild
to the end of the list of children of
this node
Get functions.
NodeList
that contains all children of this node
NamedNodeMap
containing the attributes of this node (if it
is an Element
) or null
otherwise
Document
object associated with this node
Query functions.
Set functions.
Class to refer to XML Document nodes in the DOM. Conceptually, a DOM document node is the root of the document tree, and provides the primary access to the document's data.Since elements, text nodes, comments, processing instructions, etc. cannot exist outside the context of a
Document
, theDocument
interface also contains the factory methods needed to create these objects. TheNode
objects created have aownerDocument
attribute which associates them with theDocument
within whose context they were created.
DOM_Document::createDocument().
DOM_Document(const DOM_Document &other)
DOM_Document
that refers to the
same underlying actual document as the original.
DOM_Document& operator = (const DOM_Document &other)
DOM_Document& operator = (const DOM_NullPtr *val)
The reference counting memory management will delete the underlying document itself if this DOM_Document is the last remaining to refer to the Document, and if there are no remaining references to any of the nodes within the document tree. If other live references do remain, the underlying document itself remains also.
DOM_Document
default
constructor, which creates
a null reference only, not an actual document.
This function is an extension to the DOM API, which lacks any mechanism for the creation of new documents.
DOM_Document
, which may then
be populated using the DOM API calls.
DOM_Entity createEntity(const DOMString &name)
DOM_Element createElement(const DOMString &tagName)
DOM_Element
that reference the new element.
DOM_Element createElement(const XMLCh *tagName)
DOM_Element
that reference the new element.
DOM_DocumentFragment createDocumentFragment()
DOM_DocumentFragment
that references the newly
created document fragment.
DOM_Text createTextNode(const DOMString &data)
DOM_Text
object that references the newly
created text node.
DOM_Comment createComment(const DOMString &data)
DOM_Comment
that references the newly
created comment node.
DOM_CDATASection createCDATASection(const DOMString &data)
DOM_CDATASection
object.
DOM_CDATASection
contents.
DOM_DocumentType createDocumentType(const DOMString &name)
DOM_DocumentType
that references the newly
created DocumentType node.
DOM_Notation createNotation(const DOMString &name)
DOM_Notation
that references the newly
created Notation node.
DOM_ProcessingInstruction createProcessingInstruction(const DOMString &target, const DOMString &data)
DOM_ProcessingInstruction
that references the newly
created PI node.
data - The data for the node.
DOM_Attr createAttribute(const DOMString &name)
Attr
instance can then be attached to an Element
using the DOMElement::setAttribute()
method.
DOM_Attr
that references the newly
created Attr.
DOM_EntityReference createEntityReference(const DOMString &name)
DOM_EntityReference
that references the newly
created EntityReference node.
DOM_DocumentType
) associated
with this document.
For documents without
a document type declaration this returns null
reference object. The DOM Level
1 does not support editing the Document Type Declaration, therefore
docType
cannot be altered in any way.
DOM_DOMImplementation& getImplementation() const
DOMImplementation
object that handles this document
DOM_Element getDocumentElement() const
DOM_NodeList getElementsByTagName(const DOMString &tagname) const
DOM_NodeList
of all the elements with a
given tag name. The returned node list is "live", in that changes
to the document tree made after a nodelist was initially
returned will be immediately reflected in the node list.
The elements in the node list are ordered in the same order in which they
would be encountered in a
preorder traversal of the Document
tree.
Element
s.
DOM_Node importNode(const DOM_Node &source, bool deep)
alphabetic index hierarchy of classes
XML Parser for C++ 2.0 Copyright © IBM Corp, 1999 Center for Java Technology 10275 N. De Anza Blvd. Cupertino CA 95014 USA Email: xml4c@us.ibm.com |
|