Often, scores exhaust the intervals produced by a document iterator to compute their result. However, often you also need those intervals for other purposes (maybe just because you are aggregating several interval-based scorers). Decorating a document iterator with an instance of this class you get again a document iterator, but its intervals can be retrieved several times by calling {@link #intervalIterator(Index)}, {@link #intervalIterator()} and{@link #intervalIterators()}. Important: calls are not nestable: when you require again an iterator, the one previously returned is no longer valid, and when the current document changes (e.g., because of a call to {@link #nextDocument()}) the previously returned interval iterators are invalidated. @author Sebastiano Vigna @since 0.9.1
|
|