jd.xml.xpath.model.walk
Class PrecedingWalker

java.lang.Object
  extended byjd.xml.xpath.model.walk.DescendantsWalker
      extended byjd.xml.xpath.model.walk.PrecedingWalker
All Implemented Interfaces:
ModelWalker

public class PrecedingWalker
extends DescendantsWalker

An iterator for the preceeding nodes of a node in document order. It is implemented as a DescendantsWallker starting at the root, filtering out any ancestor of the context node, and stopping at the context node.


Constructor Summary
PrecedingWalker()
           
 
Method Summary
 XPathNode gotoFirstNode(XPathNode node)
          Return the first node of the path defined by the startNode
 XPathNode gotoNextNode(XPathNode lastNode)
          Return the next node of the path.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrecedingWalker

public PrecedingWalker()
Method Detail

gotoFirstNode

public XPathNode gotoFirstNode(XPathNode node)
Description copied from interface: ModelWalker
Return the first node of the path defined by the startNode

Specified by:
gotoFirstNode in interface ModelWalker
Overrides:
gotoFirstNode in class DescendantsWalker

gotoNextNode

public XPathNode gotoNextNode(XPathNode lastNode)
Description copied from interface: ModelWalker
Return the next node of the path.

Specified by:
gotoNextNode in interface ModelWalker
Overrides:
gotoNextNode in class DescendantsWalker