| java.lang.Object org.apache.xerces.dom.NodeImpl org.apache.xerces.dom.ChildNode org.apache.xerces.dom.ParentNode org.apache.xerces.dom.CoreDocumentImpl
All known Subclasses: org.apache.xerces.dom.DocumentImpl,
CoreDocumentImpl | public class CoreDocumentImpl extends ParentNode implements Document(Code) | | The Document interface represents the entire HTML or XML document.
Conceptually, it 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, the Document
interface also contains the factory methods needed to create these
objects. The Node objects created have a ownerDocument attribute
which associates them with the Document within whose context they
were created.
The CoreDocumentImpl class only implements the DOM Core. Additional modules
are supported by the more complete DocumentImpl subclass.
Note: When any node in the document is serialized, the
entire document is serialized along with it.
author: Arnaud Le Hors, IBM author: Joe Kesselman, IBM author: Andy Clark, IBM author: Ralf Pfeiffer, IBM since: PR-DOM-Level-1-19980818. |
Field Summary | |
protected boolean | allowGrammarAccess Allow grammar access. | protected int | changes Number of alterations made to this document since its creation.
Serves as a "dirty bit" so that live objects such as NodeList can
recognize when an alteration has been made and discard its cached
state information.
Any method that alters the tree structure MUST cause or be
accompanied by a call to changed(), to inform it that any outstanding
NodeLists may have to be updated.
(Required because NodeList is simultaneously "live" and integer-
indexed -- a bad decision in the DOM's design.)
Note that changes which do not affect the tree's structure -- changing
the node's name, for example -- do _not_ have to call changed().
Alternative implementation would be to use a cryptographic
Digest value rather than a count. | protected ElementImpl | docElement Document element. | protected DocumentTypeImpl | docType Document type. | protected String | encoding | protected boolean | errorChecking Bypass error checking. | protected Hashtable | identifiers Identifiers. | protected static int[] | kidOK Table for quick check of child insertion. | final static long | serialVersionUID Serialization version. | protected boolean | standalone | protected String | version |
Method Summary | |
protected void | addEventListener(NodeImpl node, String type, EventListener listener, boolean useCapture) | public Node | adoptNode(Node source) | protected void | changed() Denotes that this node has changed. | protected int | changes() Returns the number of changes to this node. | public Object | clone() Clone. | public Node | cloneNode(boolean deep) Deep-clone a document, including fixing ownerDoc for the cloned
children. | protected void | cloneNode(CoreDocumentImpl newdoc, boolean deep) | public Attr | createAttribute(String name) Factory method; creates an Attribute having this Document as its
OwnerDoc.
Parameters: name - The name of the attribute. | public Attr | createAttributeNS(String namespaceURI, String qualifiedName) Introduced in DOM Level 2. | public CDATASection | createCDATASection(String data) Factory method; creates a CDATASection having this Document as
its OwnerDoc.
Parameters: data - The initial contents of the CDATA throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents. | public Comment | createComment(String data) Factory method; creates a Comment having this Document as its
OwnerDoc.
Parameters: data - The initial contents of the Comment. | public DocumentFragment | createDocumentFragment() Factory method; creates a DocumentFragment having this Document
as its OwnerDoc. | public DocumentType | createDocumentType(String qualifiedName, String publicID, String systemID) NON-DOM
Factory method; creates a DocumentType having this Document
as its OwnerDoc. | public Element | createElement(String tagName) Factory method; creates an Element having this Document
as its OwnerDoc.
Parameters: tagName - The name of the element type to instantiate. | public ElementDefinitionImpl | createElementDefinition(String name) NON-DOM Factory method: creates an element definition. | public Element | createElementNS(String namespaceURI, String qualifiedName) Introduced in DOM Level 2. | public Entity | createEntity(String name) NON-DOM
Factory method; creates an Entity having this Document
as its OwnerDoc. | public EntityReference | createEntityReference(String name) Factory method; creates an EntityReference having this Document
as its OwnerDoc.
Parameters: name - The name of the Entity we wish to refer to throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents, wherenonstandard entities are not permitted. | public Notation | createNotation(String name) NON-DOM
Factory method; creates a Notation having this Document
as its OwnerDoc. | public ProcessingInstruction | createProcessingInstruction(String target, String data) Factory method; creates a ProcessingInstruction having this Document
as its OwnerDoc.
Parameters: target - The target "processor channel" Parameters: data - Parameter string to be passed to the target. throws: DOMException - (INVALID_NAME_ERR) if the target name is notacceptable. throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents. | public Text | createTextNode(String data) Factory method; creates a Text node having this Document as its
OwnerDoc. | void | deletedText(NodeImpl node, int offset, int count) A method to be called when some text was deleted from a text node,
so that live objects can be notified. | protected boolean | dispatchEvent(NodeImpl node, Event event) | public DocumentType | getDoctype() For XML, this provides access to the Document Type Definition. | public Element | getDocumentElement() Convenience method, allowing direct access to the child node
which is considered the root of the actual document content. | public Element | getElementById(String elementId) Introduced in DOM Level 2
Returns the Element whose ID is given by elementId. | public NodeList | getElementsByTagName(String tagname) Return a live collection of all descendent Elements (not just
immediate children) having the specified tag name.
Parameters: tagname - The type of Element we want to gather. | public NodeList | getElementsByTagNameNS(String namespaceURI, String localName) Introduced in DOM Level 2. | public String | getEncoding() DOM Level 3 WD - Experimental. | public boolean | getErrorChecking() Returns true if the DOM implementation performs error checking. | public Element | getIdentifier(String idName) Returns a previously registered element with the specified
identifier name, or null if no element is registered. | public Enumeration | getIdentifiers() Returns an enumeration registered of identifier names. | public DOMImplementation | getImplementation() Retrieve information describing the abilities of this particular
DOM implementation. | boolean | getMutationEvents() Returns true if the DOM implementation generates mutation events. | public String | getNodeName() Returns the node name. | public short | getNodeType() Returns the node type. | final public Document | getOwnerDocument() | public boolean | getStandalone() DOM Level 3 WD - Experimental. | public boolean | getStrictErrorChecking() | protected Object | getUserData(NodeImpl n) | public String | getVersion() DOM Level 3 WD - Experimental. | public Node | importNode(Node source, boolean deep) Copies a node from another document to this document. | public Node | insertBefore(Node newChild, Node refChild) Since a Document may contain at most one top-level Element child,
and at most one DocumentType declaraction, we need to subclass our
add-children methods to implement this constraint. | void | insertedNode(NodeImpl node, NodeImpl newInternal, boolean replace) A method to be called when a node has been inserted in the tree. | void | insertedText(NodeImpl node, int offset, int count) A method to be called when some text was inserted into a text node,
so that live objects can be notified. | void | insertingNode(NodeImpl node, boolean replace) A method to be called when a node is about to be inserted in the tree. | protected boolean | isKidOK(Node parent, Node child) Uses the kidOK lookup table to check whether the proposed
tree structure is legal. | public static boolean | isXMLName(String s) | void | modifiedAttrValue(AttrImpl attr, String oldvalue) | void | modifiedCharacterData(NodeImpl node, String oldvalue, String value) | void | modifyingCharacterData(NodeImpl node) | public void | putIdentifier(String idName, Element element) Registers an identifier name with a specified element node.
If the identifier is already registered, the new element
node replaces the previous node. | public Node | removeChild(Node oldChild) | protected void | removeEventListener(NodeImpl node, String type, EventListener listener, boolean useCapture) | public void | removeIdentifier(String idName) Removes a previously registered element with the specified
identifier name. | void | removedAttrNode(AttrImpl attr, NodeImpl oldOwner, String name) | void | removedNode(NodeImpl node, boolean replace) A method to be called when a node has been removed from the tree. | void | removingNode(NodeImpl node, NodeImpl oldChild, boolean replace) A method to be called when a node is about to be removed from the tree. | public Node | replaceChild(Node newChild, Node oldChild) | void | replacedNode(NodeImpl node) A method to be called when a node has been replaced in the tree. | void | replacedText(NodeImpl node) A method to be called when some text was changed in a text node,
so that live objects can be notified. | void | replacingNode(NodeImpl node) A method to be called when a node is about to be replaced in the tree. | void | setAttrNode(AttrImpl attr, AttrImpl previous) | public void | setEncoding(String value) DOM Level 3 WD - Experimental.
An attribute specifying, as part of the XML declaration,
the encoding of this document. | public void | setErrorChecking(boolean check) Sets whether the DOM implementation performs error checking
upon operations. | void | setMutationEvents(boolean set) Sets whether the DOM implementation generates mutation events
upon operations. | public void | setStandalone(boolean value) DOM Level 3 WD - Experimental. | public void | setStrictErrorChecking(boolean check) | protected void | setUserData(NodeImpl n, Object data) Store user data related to a given node
This is a place where we could use weak references! Indeed, the node
here won't be GC'ed as long as some user data is attached to it, since
the userData table will have a reference to the node. | public void | setVersion(String value) DOM Level 3 WD - Experimental.
version - An attribute specifying, as part of the XML declaration,
the version number of this document. |
allowGrammarAccess | protected boolean allowGrammarAccess(Code) | | Allow grammar access.
|
changes | protected int changes(Code) | | Number of alterations made to this document since its creation.
Serves as a "dirty bit" so that live objects such as NodeList can
recognize when an alteration has been made and discard its cached
state information.
Any method that alters the tree structure MUST cause or be
accompanied by a call to changed(), to inform it that any outstanding
NodeLists may have to be updated.
(Required because NodeList is simultaneously "live" and integer-
indexed -- a bad decision in the DOM's design.)
Note that changes which do not affect the tree's structure -- changing
the node's name, for example -- do _not_ have to call changed().
Alternative implementation would be to use a cryptographic
Digest value rather than a count. This would have the advantage that
"harmless" changes (those producing equal() trees) would not force
NodeList to resynchronize. Disadvantage is that it's slightly more prone
to "false negatives", though that's the difference between "wildly
unlikely" and "absurdly unlikely". IF we start maintaining digests,
we should consider taking advantage of them.
Note: This used to be done a node basis, so that we knew what
subtree changed. But since only DeepNodeList really use this today,
the gain appears to be really small compared to the cost of having
an int on every (parent) node plus having to walk up the tree all the
way to the root to mark the branch as changed everytime a node is
changed.
So we now have a single counter global to the document. It means that
some objects may flush their cache more often than necessary, but this
makes nodes smaller and only the document needs to be marked as changed.
|
encoding | protected String encoding(Code) | | Experimental DOM Level 3 feature: Document encoding
|
errorChecking | protected boolean errorChecking(Code) | | Bypass error checking.
|
kidOK | protected static int[] kidOK(Code) | | Table for quick check of child insertion.
|
serialVersionUID | final static long serialVersionUID(Code) | | Serialization version.
|
standalone | protected boolean standalone(Code) | | Experimental DOM Level 3 feature: Document standalone
|
version | protected String version(Code) | | Experimental DOM Level 3 feature: Document version
|
CoreDocumentImpl | public CoreDocumentImpl()(Code) | | NON-DOM: Actually creating a Document is outside the DOM's spec,
since it has to operate in terms of a particular implementation.
|
CoreDocumentImpl | public CoreDocumentImpl(boolean grammarAccess)(Code) | | Constructor.
|
CoreDocumentImpl | public CoreDocumentImpl(DocumentType doctype)(Code) | | For DOM2 support.
The createDocument factory method is in DOMImplementation.
|
CoreDocumentImpl | public CoreDocumentImpl(DocumentType doctype, boolean grammarAccess)(Code) | | For DOM2 support.
|
adoptNode | public Node adoptNode(Node source)(Code) | | DOM Level 3 WD - Experimental
Change the node's ownerDocument, and its subtree, to this Document
Parameters: source - The node to adopt. See Also: DocumentImpl.importNode |
changed | protected void changed()(Code) | | Denotes that this node has changed.
|
changes | protected int changes()(Code) | | Returns the number of changes to this node.
|
cloneNode | public Node cloneNode(boolean deep)(Code) | | Deep-clone a document, including fixing ownerDoc for the cloned
children. Note that this requires bypassing the WRONG_DOCUMENT_ERR
protection. I've chosen to implement it by calling importNode
which is DOM Level 2.
org.w3c.dom.Node Parameters: deep - boolean, iff true replicate children |
cloneNode | protected void cloneNode(CoreDocumentImpl newdoc, boolean deep)(Code) | | internal method to share code with subclass
|
createAttribute | public Attr createAttribute(String name) throws DOMException(Code) | | Factory method; creates an Attribute having this Document as its
OwnerDoc.
Parameters: name - The name of the attribute. Note that the attribute's valueis _not_ established at the factory; remember to set it! throws: DOMException - (INVALID_NAME_ERR) if the attribute name is notacceptable. |
createAttributeNS | public Attr createAttributeNS(String namespaceURI, String qualifiedName) throws DOMException(Code) | | Introduced in DOM Level 2.
Creates an attribute of the given qualified name and namespace URI.
If the given namespaceURI is null or an empty string and the
qualifiedName has a prefix that is "xml", the created element
is bound to the predefined namespace
"http://www.w3.org/XML/1998/namespace" [Namespaces].
Parameters: namespaceURI - The namespace URI of the attribute tocreate. When it is null or an empty string,this method behaves like createAttribute. Parameters: qualifiedName - The qualified name of the attribute toinstantiate. Attr A new Attr object. throws: DOMException - INVALID_CHARACTER_ERR: Raised if the specifiedname contains an invalid character. since: WD-DOM-Level-2-19990923 |
createCDATASection | public CDATASection createCDATASection(String data) throws DOMException(Code) | | Factory method; creates a CDATASection having this Document as
its OwnerDoc.
Parameters: data - The initial contents of the CDATA throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents. (HTMLnot yet implemented.) |
createComment | public Comment createComment(String data)(Code) | | Factory method; creates a Comment having this Document as its
OwnerDoc.
Parameters: data - The initial contents of the Comment. |
createDocumentFragment | public DocumentFragment createDocumentFragment()(Code) | | Factory method; creates a DocumentFragment having this Document
as its OwnerDoc.
|
createDocumentType | public DocumentType createDocumentType(String qualifiedName, String publicID, String systemID) throws DOMException(Code) | | NON-DOM
Factory method; creates a DocumentType having this Document
as its OwnerDoc. (REC-DOM-Level-1-19981001 left the process of building
DTD information unspecified.)
Parameters: name - The name of the Entity we wish to provide a value for. throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents, whereDTDs are not permitted. (HTML not yet implemented.) |
createElement | public Element createElement(String tagName) throws DOMException(Code) | | Factory method; creates an Element having this Document
as its OwnerDoc.
Parameters: tagName - The name of the element type to instantiate. ForXML, this is case-sensitive. For HTML, the tagName parameter maybe provided in any case, but it must be mapped to the canonicaluppercase form by the DOM implementation. throws: DOMException - (INVALID_NAME_ERR) if the tag name is notacceptable. |
createElementNS | public Element createElementNS(String namespaceURI, String qualifiedName) throws DOMException(Code) | | Introduced in DOM Level 2.
Creates an element of the given qualified name and namespace URI.
If the given namespaceURI is null or an empty string and the
qualifiedName has a prefix that is "xml", the created element
is bound to the predefined namespace
"http://www.w3.org/XML/1998/namespace" [Namespaces].
Parameters: namespaceURI - The namespace URI of the element tocreate. Parameters: qualifiedName - The qualified name of the element type toinstantiate. Element A new Element object with the following attributes: throws: DOMException - INVALID_CHARACTER_ERR: Raised if the specifiedname contains an invalid character. throws: DOMException - NAMESPACE_ERR: Raised if the qualifiedName has aprefix that is "xml" and the namespaceURI isneither null nor an empty string nor"http://www.w3.org/XML/1998/namespace", orif the qualifiedName has a prefix differentfrom "xml" and the namespaceURI is null or anempty string. since: WD-DOM-Level-2-19990923 |
createEntity | public Entity createEntity(String name) throws DOMException(Code) | | NON-DOM
Factory method; creates an Entity having this Document
as its OwnerDoc. (REC-DOM-Level-1-19981001 left the process of building
DTD information unspecified.)
Parameters: name - The name of the Entity we wish to provide a value for. throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents, wherenonstandard entities are not permitted. (HTML not yetimplemented.) |
createEntityReference | public EntityReference createEntityReference(String name) throws DOMException(Code) | | Factory method; creates an EntityReference having this Document
as its OwnerDoc.
Parameters: name - The name of the Entity we wish to refer to throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents, wherenonstandard entities are not permitted. (HTML not yetimplemented.) |
createNotation | public Notation createNotation(String name) throws DOMException(Code) | | NON-DOM
Factory method; creates a Notation having this Document
as its OwnerDoc. (REC-DOM-Level-1-19981001 left the process of building
DTD information unspecified.)
Parameters: name - The name of the Notation we wish to describe throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents, wherenotations are not permitted. (HTML not yetimplemented.) |
createProcessingInstruction | public ProcessingInstruction createProcessingInstruction(String target, String data) throws DOMException(Code) | | Factory method; creates a ProcessingInstruction having this Document
as its OwnerDoc.
Parameters: target - The target "processor channel" Parameters: data - Parameter string to be passed to the target. throws: DOMException - (INVALID_NAME_ERR) if the target name is notacceptable. throws: DOMException - (NOT_SUPPORTED_ERR) for HTML documents. (HTMLnot yet implemented.) |
createTextNode | public Text createTextNode(String data)(Code) | | Factory method; creates a Text node having this Document as its
OwnerDoc.
Parameters: data - The initial contents of the Text. |
deletedText | void deletedText(NodeImpl node, int offset, int count)(Code) | | A method to be called when some text was deleted from a text node,
so that live objects can be notified.
|
getDoctype | public DocumentType getDoctype()(Code) | | For XML, this provides access to the Document Type Definition.
For HTML documents, and XML documents which don't specify a DTD,
it will be null.
|
getDocumentElement | public Element getDocumentElement()(Code) | | Convenience method, allowing direct access to the child node
which is considered the root of the actual document content. For
HTML, where it is legal to have more than one Element at the top
level of the document, we pick the one with the tagName
"HTML". For XML there should be only one top-level
(HTML not yet supported.)
|
getElementById | public Element getElementById(String elementId)(Code) | | Introduced in DOM Level 2
Returns the Element whose ID is given by elementId. If no such element
exists, returns null. Behavior is not defined if more than one element
has this ID.
Note: The DOM implementation must have information that says which
attributes are of type ID. Attributes with the name "ID" are not of type
ID unless so defined. Implementations that do not know whether
attributes are of type ID or not are expected to return null.
See Also: CoreDocumentImpl.getIdentifier |
getElementsByTagName | public NodeList getElementsByTagName(String tagname)(Code) | | Return a live collection of all descendent Elements (not just
immediate children) having the specified tag name.
Parameters: tagname - The type of Element we want to gather. "*" will betaken as a wildcard, meaning "all elements in the document." See Also: DeepNodeListImpl |
getElementsByTagNameNS | public NodeList getElementsByTagNameNS(String namespaceURI, String localName)(Code) | | Introduced in DOM Level 2.
Returns a NodeList of all the Elements with a given local name and
namespace URI in the order in which they would be encountered in a
preorder traversal of the Document tree.
Parameters: namespaceURI - The namespace URI of the elements to matchon. The special value "*" matches allnamespaces. When it is null or an emptystring, this method behaves likegetElementsByTagName. Parameters: localName - The local name of the elements to match on.The special value "*" matches all local names. NodeList A new NodeList object containing all the matchedElements. since: WD-DOM-Level-2-19990923 |
getEncoding | public String getEncoding()(Code) | | DOM Level 3 WD - Experimental.
The encoding of this document (part of XML Declaration)
|
getErrorChecking | public boolean getErrorChecking()(Code) | | Returns true if the DOM implementation performs error checking.
|
getIdentifiers | public Enumeration getIdentifiers()(Code) | | Returns an enumeration registered of identifier names.
|
getImplementation | public DOMImplementation getImplementation()(Code) | | Retrieve information describing the abilities of this particular
DOM implementation. Intended to support applications that may be
using DOMs retrieved from several different sources, potentially
with different underlying representations.
|
getMutationEvents | boolean getMutationEvents()(Code) | | Returns true if the DOM implementation generates mutation events.
|
getNodeName | public String getNodeName()(Code) | | Returns the node name.
|
getNodeType | public short getNodeType()(Code) | | Returns the node type.
|
getStandalone | public boolean getStandalone()(Code) | | DOM Level 3 WD - Experimental.
standalone that specifies whether this document is standalone
(part of XML Declaration)
|
getStrictErrorChecking | public boolean getStrictErrorChecking()(Code) | | |
getUserData | protected Object getUserData(NodeImpl n)(Code) | | Retreive user data related to a given node
|
getVersion | public String getVersion()(Code) | | DOM Level 3 WD - Experimental.
The version of this document (part of XML Declaration)
|
importNode | public Node importNode(Node source, boolean deep) throws DOMException(Code) | | Copies a node from another document to this document. The new nodes are
created using this document's factory methods and are populated with the
data from the source's accessor methods defined by the DOM interfaces.
Its behavior is otherwise similar to that of cloneNode.
According to the DOM specifications, document nodes cannot be imported
and a NOT_SUPPORTED_ERR exception is thrown if attempted.
|
insertBefore | public Node insertBefore(Node newChild, Node refChild) throws DOMException(Code) | | Since a Document may contain at most one top-level Element child,
and at most one DocumentType declaraction, we need to subclass our
add-children methods to implement this constraint.
Since appendChild() is implemented as insertBefore(,null),
altering the latter fixes both.
While I'm doing so, I've taken advantage of the opportunity to
cache documentElement and docType so we don't have to
search for them.
REVISIT: According to the spec it is not allowed to alter neither the
document element nor the document type in any way
|
insertedNode | void insertedNode(NodeImpl node, NodeImpl newInternal, boolean replace)(Code) | | A method to be called when a node has been inserted in the tree.
|
insertedText | void insertedText(NodeImpl node, int offset, int count)(Code) | | A method to be called when some text was inserted into a text node,
so that live objects can be notified.
|
insertingNode | void insertingNode(NodeImpl node, boolean replace)(Code) | | A method to be called when a node is about to be inserted in the tree.
|
isKidOK | protected boolean isKidOK(Node parent, Node child)(Code) | | Uses the kidOK lookup table to check whether the proposed
tree structure is legal.
|
isXMLName | public static boolean isXMLName(String s)(Code) | | Check the string against XML's definition of acceptable names for
elements and attributes and so on using the XMLCharacterProperties
utility class
|
modifiedAttrValue | void modifiedAttrValue(AttrImpl attr, String oldvalue)(Code) | | A method to be called when an attribute value has been modified
|
modifiedCharacterData | void modifiedCharacterData(NodeImpl node, String oldvalue, String value)(Code) | | A method to be called when a character data node has been modified
|
modifyingCharacterData | void modifyingCharacterData(NodeImpl node)(Code) | | A method to be called when a character data node has been modified
|
removeChild | public Node removeChild(Node oldChild) throws DOMException(Code) | | Since insertBefore caches the docElement (and, currently, docType),
removeChild has to know how to undo the cache
REVISIT: According to the spec it is not allowed to alter neither the
document element nor the document type in any way
|
removedAttrNode | void removedAttrNode(AttrImpl attr, NodeImpl oldOwner, String name)(Code) | | A method to be called when an attribute node has been removed
|
removedNode | void removedNode(NodeImpl node, boolean replace)(Code) | | A method to be called when a node has been removed from the tree.
|
removingNode | void removingNode(NodeImpl node, NodeImpl oldChild, boolean replace)(Code) | | A method to be called when a node is about to be removed from the tree.
|
replaceChild | public Node replaceChild(Node newChild, Node oldChild) throws DOMException(Code) | | Since we cache the docElement (and, currently, docType),
replaceChild has to update the cache
REVISIT: According to the spec it is not allowed to alter neither the
document element nor the document type in any way
|
replacedNode | void replacedNode(NodeImpl node)(Code) | | A method to be called when a node has been replaced in the tree.
|
replacedText | void replacedText(NodeImpl node)(Code) | | A method to be called when some text was changed in a text node,
so that live objects can be notified.
|
replacingNode | void replacingNode(NodeImpl node)(Code) | | A method to be called when a node is about to be replaced in the tree.
|
setAttrNode | void setAttrNode(AttrImpl attr, AttrImpl previous)(Code) | | A method to be called when an attribute node has been set
|
setEncoding | public void setEncoding(String value)(Code) | | DOM Level 3 WD - Experimental.
An attribute specifying, as part of the XML declaration,
the encoding of this document. This is null when unspecified.
|
setErrorChecking | public void setErrorChecking(boolean check)(Code) | | Sets whether the DOM implementation performs error checking
upon operations. Turning off error checking only affects
the following DOM checks:
- Checking strings to make sure that all characters are
legal XML characters
- Hierarchy checking such as allowed children, checks for
cycles, etc.
Turning off error checking does not turn off the
following checks:
- Read only checks
- Checks related to DOM events
|
setMutationEvents | void setMutationEvents(boolean set)(Code) | | Sets whether the DOM implementation generates mutation events
upon operations.
|
setStandalone | public void setStandalone(boolean value)(Code) | | DOM Level 3 WD - Experimental.
standalone - An attribute specifying, as part of the XML declaration,
whether this document is standalone
|
setStrictErrorChecking | public void setStrictErrorChecking(boolean check)(Code) | | |
setUserData | protected void setUserData(NodeImpl n, Object data)(Code) | | Store user data related to a given node
This is a place where we could use weak references! Indeed, the node
here won't be GC'ed as long as some user data is attached to it, since
the userData table will have a reference to the node.
|
setVersion | public void setVersion(String value)(Code) | | DOM Level 3 WD - Experimental.
version - An attribute specifying, as part of the XML declaration,
the version number of this document. This is null when unspecified
|
|
|