Top Description Fields Constructors Methods
com.sun.org.apache.xerces.internal.dom

public Class TreeWalkerImpl

extends Object
implements TreeWalker
Class Inheritance
All Implemented Interfaces
org.w3c.dom.traversal.TreeWalker
Imports
org.w3c.dom.DOMException, .Node, org.w3c.dom.traversal.NodeFilter, .TreeWalker

This class implements the TreeWalker interface.

Field Summary

Modifier and TypeField and Description
pack-priv Node
fCurrentNode

The current Node.

private boolean
fEntityReferenceExpansion

When TRUE, the children of entites references are returned in the iterator.

pack-priv NodeFilter
fNodeFilter

The NodeFilter reference.

pack-priv Node
fRoot

The root Node.

pack-priv int
fWhatToShow

The whatToShow mask.

Constructor Summary

AccessConstructor and Description
public
TreeWalkerImpl(Node root, int whatToShow, NodeFilter nodeFilter, boolean entityReferenceExpansion)

Public constructor

Method Summary

Modifier and TypeMethod and Description
pack-priv short
acceptNode(Node node)

Internal function.

public Node
firstChild()

Implements org.w3c.dom.traversal.TreeWalker.firstChild.

Return the first child Node from the current node, after applying filter, whatToshow.

public Node
public boolean
getExpandEntityReferences()

Implements org.w3c.dom.traversal.TreeWalker.getExpandEntityReferences.

Return whether children entity references are included in the iterator.

public NodeFilter
getFilter()

Implements org.w3c.dom.traversal.TreeWalker.getFilter.

Return the NodeFilter

pack-priv Node
getFirstChild(Node node)

Internal function.

pack-priv Node
getLastChild(Node node)

Internal function.

pack-priv Node
getNextSibling(Node node)

Internal function.

pack-priv Node
getNextSibling(Node node, Node root)

Internal function.

pack-priv Node
getParentNode(Node node)

Internal function.

pack-priv Node
getPreviousSibling(Node node)

Internal function.

pack-priv Node
getPreviousSibling(Node node, Node root)

Internal function.

public Node
getRoot()

Implements org.w3c.dom.traversal.TreeWalker.getRoot.

The root node of the TreeWalker, as specified when it was created.

public int
getWhatToShow()

Implements org.w3c.dom.traversal.TreeWalker.getWhatToShow.

Return the whatToShow value

public Node
lastChild()

Implements org.w3c.dom.traversal.TreeWalker.lastChild.

Return the last child Node from the current node, after applying filter, whatToshow.

public Node
nextNode()

Implements org.w3c.dom.traversal.TreeWalker.nextNode.

Return the next Node from the current node, after applying filter, whatToshow.

public Node
nextSibling()

Implements org.w3c.dom.traversal.TreeWalker.nextSibling.

Return the next sibling Node from the current node, after applying filter, whatToshow.

public Node
parentNode()

Implements org.w3c.dom.traversal.TreeWalker.parentNode.

Return the parent Node from the current node, after applying filter, whatToshow.

public Node
previousNode()

Implements org.w3c.dom.traversal.TreeWalker.previousNode.

Return the previous Node from the current node, after applying filter, whatToshow.

public Node
previousSibling()

Implements org.w3c.dom.traversal.TreeWalker.previousSibling.

Return the previous sibling Node from the current node, after applying filter, whatToshow.

public void
setCurrentNode(Node node)

Implements org.w3c.dom.traversal.TreeWalker.setCurrentNode.

Return the current Node.

public void
setWhatShow(int whatToShow)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

fCurrentNodeback to summary
pack-priv Node fCurrentNode

The current Node.

fEntityReferenceExpansionback to summary
private boolean fEntityReferenceExpansion

When TRUE, the children of entites references are returned in the iterator.

fNodeFilterback to summary
pack-priv NodeFilter fNodeFilter

The NodeFilter reference.

fRootback to summary
pack-priv Node fRoot

The root Node.

fWhatToShowback to summary
pack-priv int fWhatToShow

The whatToShow mask.

Constructor Detail

TreeWalkerImplback to summary
public TreeWalkerImpl(Node root, int whatToShow, NodeFilter nodeFilter, boolean entityReferenceExpansion)

Public constructor

Method Detail

acceptNodeback to summary
pack-priv short acceptNode(Node node)

Internal function. The node whatToShow and the filter are combined into one result.

firstChildback to summary
public Node firstChild()

Implements org.w3c.dom.traversal.TreeWalker.firstChild.

Return the first child Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.firstChild.

The new node, or null if the current node has no visible children in the TreeWalker's logical view.

getCurrentNodeback to summary
public Node getCurrentNode()

Implements org.w3c.dom.traversal.TreeWalker.getCurrentNode.

Return the current Node.

getExpandEntityReferencesback to summary
public boolean getExpandEntityReferences()

Implements org.w3c.dom.traversal.TreeWalker.getExpandEntityReferences.

Return whether children entity references are included in the iterator.

getFilterback to summary
public NodeFilter getFilter()

Implements org.w3c.dom.traversal.TreeWalker.getFilter.

Return the NodeFilter

getFirstChildback to summary
pack-priv Node getFirstChild(Node node)

Internal function. Return the first child Node, from the input node after applying filter, whatToshow. The current node is not consulted or set.

getLastChildback to summary
pack-priv Node getLastChild(Node node)

Internal function. Return the last child Node, from the input node after applying filter, whatToshow. The current node is not consulted or set.

getNextSiblingback to summary
pack-priv Node getNextSibling(Node node)

Internal function. Return the nextSibling Node, from the input node after applying filter, whatToshow. The current node is not consulted or set.

getNextSiblingback to summary
pack-priv Node getNextSibling(Node node, Node root)

Internal function. Return the nextSibling Node, from the input node after applying filter, whatToshow. NEVER TRAVERSES ABOVE THE SPECIFIED ROOT NODE. The current node is not consulted or set.

getParentNodeback to summary
pack-priv Node getParentNode(Node node)

Internal function. Return the parent Node, from the input node after applying filter, whatToshow. The current node is not consulted or set.

getPreviousSiblingback to summary
pack-priv Node getPreviousSibling(Node node)

Internal function. Return the previous sibling Node, from the input node after applying filter, whatToshow. The current node is not consulted or set.

getPreviousSiblingback to summary
pack-priv Node getPreviousSibling(Node node, Node root)

Internal function. Return the previousSibling Node, from the input node after applying filter, whatToshow. NEVER TRAVERSES ABOVE THE SPECIFIED ROOT NODE. The current node is not consulted or set.

getRootback to summary
public Node getRoot()

Implements org.w3c.dom.traversal.TreeWalker.getRoot.

Doc from org.w3c.dom.traversal.TreeWalker.getRoot.

The root node of the TreeWalker, as specified when it was created.

getWhatToShowback to summary
public int getWhatToShow()

Implements org.w3c.dom.traversal.TreeWalker.getWhatToShow.

Return the whatToShow value

lastChildback to summary
public Node lastChild()

Implements org.w3c.dom.traversal.TreeWalker.lastChild.

Return the last child Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.lastChild.

The new node, or null if the current node has no children in the TreeWalker's logical view.

nextNodeback to summary
public Node nextNode()

Implements org.w3c.dom.traversal.TreeWalker.nextNode.

Return the next Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.nextNode.

The new node, or null if the current node has no next node in the TreeWalker's logical view.

nextSiblingback to summary
public Node nextSibling()

Implements org.w3c.dom.traversal.TreeWalker.nextSibling.

Return the next sibling Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.nextSibling.

The new node, or null if the current node has no next sibling. in the TreeWalker's logical view.

parentNodeback to summary
public Node parentNode()

Implements org.w3c.dom.traversal.TreeWalker.parentNode.

Return the parent Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.parentNode.

The new parent node, or null if the current node has no parent in the TreeWalker's logical view.

previousNodeback to summary
public Node previousNode()

Implements org.w3c.dom.traversal.TreeWalker.previousNode.

Return the previous Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.previousNode.

The new node, or null if the current node has no previous node in the TreeWalker's logical view.

previousSiblingback to summary
public Node previousSibling()

Implements org.w3c.dom.traversal.TreeWalker.previousSibling.

Return the previous sibling Node from the current node, after applying filter, whatToshow. If result is not null, set the current Node.

Returns:Node

Doc from org.w3c.dom.traversal.TreeWalker.previousSibling.

The new node, or null if the current node has no previous sibling. in the TreeWalker's logical view.

setCurrentNodeback to summary
public void setCurrentNode(Node node)

Implements org.w3c.dom.traversal.TreeWalker.setCurrentNode.

Return the current Node.

setWhatShowback to summary
public void setWhatShow(int whatToShow)