A singleton iterator representing maximum truth.
This iterator is a placeholder for an iterator returning just
Intervals.EMPTY_INTERVAL .
The antichain formed by the empty interval is the top element of the lattice of antichains, and
thus represents the highest truth. Since, however, EMPTY_INTERVAL
is a singleton that slightly violates the
Interval invariants, an iterator actually
returning EMPTY_INTERVAL would cause severe problems in all algorithms manipulating
intervals. Rather,
IntervalIterators.TRUE is treated separately and is never actually used in
an algorithm on interval antichains (also because, albeit it claims to have elements,
it will return null on
IntervalIterator.nextInterval ).
A most natural appearance of
IntervalIterators.TRUE is due to negation: all documents satisfying
a negative query return
IntervalIterators.TRUE as interval iterator.
Finally, an
IndexIterator by convention returns
IntervalIterators.TRUE
when
DocumentIterator.intervalIterator(it.unimi.dsi.mg4j.index.Index)
is called with an argument that is not the
.
The idea is that there is no witness to be returned, but the query is nonetheless true.
|