net.sf.saxon.expr
Class UnionEnumeration
java.lang.Object
net.sf.saxon.expr.UnionEnumeration
- LookaheadIterator, SequenceIterator
public class UnionEnumeration
extends java.lang.Object
An enumeration representing a nodeset that is a union of two other NodeSets.
UnionEnumeration
public UnionEnumeration(SequenceIterator p1,
SequenceIterator p2,
NodeOrderComparer comparer)
throws XPathException
Create the iterator. The two input iterators must return nodes in document
order for this to work.
p1
- iterator over the first operand sequence (in document order)p2
- iterator over the second operand sequencecomparer
- used to test whether nodes are in document order. Different versions
are used for intra-document and cross-document operations
getProperties
public int getProperties()
Get properties of this iterator, as a bit-significant integer.
- getProperties in interface SequenceIterator
hasNext
public boolean hasNext()
Determine whether there are more items to come. Note that this operation
is stateless and it is not necessary (or usual) to call it before calling
next(). It is used only when there is an explicit need to tell if we
are at the last element.
This method must not be called unless the result of getProperties() on the iterator
includes the bit setting
SequenceIterator.LOOKAHEAD
- hasNext in interface LookaheadIterator
- true if there are more items in the sequence