org.apache.commons.jxpath.ri.axes
Class UnionContext
- ExpressionContext, Iterator
public class UnionContext
EvalContext that represents a union between other contexts - result
of a union operation like (a | b)
$Revision: 1.12 $ $Date: 2004/02/29 14:17:38 $
int | getDocumentOrder() - Determines the document order for this context.
|
boolean | setPosition(int position) - Moves the current position to the specified index.
|
getContextNodeList , getContextNodePointer , getCurrentNodePointer , getCurrentPosition , getDocumentOrder , getJXPathContext , getNodeSet , getPosition , getRootContext , getSingleNodePointer , getValue , hasNext , isChildOrderingRequired , next , nextNode , nextSet , remove , reset , setPosition , toString |
UnionContext
public UnionContext(EvalContext parentContext,
contexts[] )
getDocumentOrder
public int getDocumentOrder()
Determines the document order for this context.
- getDocumentOrder in interface EvalContext
- 1 ascending order, -1 descending order,
0 - does not require ordering
setPosition
public boolean setPosition(int position)
Moves the current position to the specified index. Used with integer
predicates to quickly get to the n'th element of the node set.
Returns false if the position is out of the node set range.
You can call it with 0 as the position argument to restart the iteration.
- setPosition in interface NodeSetContext