Class ChildNode
java.lang.Object
org.htmlunit.cyberneko.xerces.dom.NodeImpl
org.htmlunit.cyberneko.xerces.dom.ChildNode
- All Implemented Interfaces:
Cloneable
,EventTarget
,Node
,NodeList
- Direct Known Subclasses:
CharacterDataImpl
,ParentNode
ChildNode inherits from NodeImpl and adds the capability of being a child by
having references to its previous and next siblings.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ChildNode
Next sibling.protected ChildNode
Previous sibling.Fields inherited from class org.htmlunit.cyberneko.xerces.dom.NodeImpl
DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_IS_CONTAINED, DOCUMENT_POSITION_PRECEDING, FIRSTCHILD, HASSTRING, ID, NORMALIZED, OWNED, ownerNode_, READONLY, SPECIFIED, SYNCCHILDREN
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
ChildNode
(CoreDocumentImpl ownerDocument) No public constructor; only subclasses of Node should be instantiated, and those normally via a Document's factory methods -
Method Summary
Modifier and TypeMethodDescriptioncloneNode
(boolean deep) Returns a duplicate of a given node.The next child of this node's parent, or null if noneObtain the DOM-tree parent of this node, or null if it is not currently active in the DOM tree (perhaps because it has just been created or removed).The previous child of this node's parent, or null if none(package private) final NodeImpl
(package private) final ChildNode
Methods inherited from class org.htmlunit.cyberneko.xerces.dom.NodeImpl
addEventListener, appendChild, changed, changes, compareDocumentPosition, dispatchEvent, getAttributes, getBaseURI, getChildNodes, getElementAncestor, getFeature, getFirstChild, getLastChild, getLength, getLocalName, getNamespaceURI, getNodeName, getNodeNumber, getNodeType, getNodeValue, getOwnerDocument, getPrefix, getTextContent, getTextContent, getUserData, hasAttributes, hasChildNodes, hasStringValue, hasStringValue, insertBefore, isDefaultNamespace, isEqualNode, isFirstChild, isFirstChild, isIdAttribute, isIdAttribute, isNormalized, isNormalized, isOwned, isOwned, isSameNode, isSpecified, isSpecified, isSupported, item, lookupNamespacePrefix, lookupNamespaceURI, lookupPrefix, needsSyncChildren, needsSyncChildren, normalize, ownerDocument, removeChild, removeEventListener, replaceChild, setNodeValue, setOwnerDocument, setPrefix, setTextContent, setUserData, toString
-
Field Details
-
previousSibling_
Previous sibling. -
nextSibling_
Next sibling.
-
-
Constructor Details
-
ChildNode
No public constructor; only subclasses of Node should be instantiated, and those normally via a Document's factory methodsEvery Node knows what Document it belongs to.
- Parameters:
ownerDocument
- the owner document
-
-
Method Details
-
cloneNode
Returns a duplicate of a given node. You can consider this a generic "copy constructor" for nodes. The newly returned object should be completely independent of the source object's subtree, so changes in one after the clone has been made will not affect the other.Note: since we never have any children deep is meaningless here, ParentNode overrides this behavior. Returns a duplicate of a given node. You can consider this a generic "copy constructor" for nodes. The newly returned object should be completely independent of the source object's subtree, so changes in one after the clone has been made will not affect the other.
Note: since we never have any children deep is meaningless here, ParentNode overrides this behavior.
-
getParentNode
Obtain the DOM-tree parent of this node, or null if it is not currently active in the DOM tree (perhaps because it has just been created or removed). Note that Document, DocumentFragment, and Attribute will never have parents.- Specified by:
getParentNode
in interfaceNode
- Overrides:
getParentNode
in classNodeImpl
-
parentNode
- Overrides:
parentNode
in classNodeImpl
-
getNextSibling
The next child of this node's parent, or null if none The next child of this node's parent, or null if none- Specified by:
getNextSibling
in interfaceNode
- Overrides:
getNextSibling
in classNodeImpl
-
getPreviousSibling
The previous child of this node's parent, or null if none- Specified by:
getPreviousSibling
in interfaceNode
- Overrides:
getPreviousSibling
in classNodeImpl
-
previousSibling
- Overrides:
previousSibling
in classNodeImpl
-