|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.core.query.lucene.hits.ArrayHits
public class ArrayHits
Uses an integer array to store the hit set. This implementation uses less
memory than BitSetHits if the total number of documents is high and
and the number of hits is low or if your hits doc numbers are mostly in the
upper part of your doc number range.
If you don't know about your hit distribution in advance use
AdaptingHits instead.
| Constructor Summary | |
|---|---|
ArrayHits()
|
|
ArrayHits(int initialSize)
|
|
| Method Summary | |
|---|---|
int |
next()
Return the doc number of the next hit in the set. |
void |
set(int doc)
Marks the document with doc number doc as a hit. |
int |
skipTo(int target)
Skips to the first match beyond the current whose document number is greater than or equal to the given target. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ArrayHits()
public ArrayHits(int initialSize)
| Method Detail |
|---|
public void set(int doc)
doc as a hit.
Implementations may throw an exception if you call set() after next() or
skipTo() has been called.
set in interface Hitspublic int next()
next in interface Hitspublic int skipTo(int target)
skipTo in interface Hits
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||