|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.lucene.codecs.MultiLevelSkipListReader
public abstract class MultiLevelSkipListReader
This abstract class reads skip lists with multiple levels.
See MultiLevelSkipListWriter
for the information about the encoding
of the multi level skip lists.
Subclasses must implement the abstract method readSkipData(int, IndexInput)
which defines the actual format of the skip data.
Field Summary | |
---|---|
protected int |
maxNumberOfSkipLevels
|
Constructor Summary | |
---|---|
MultiLevelSkipListReader(IndexInput skipStream,
int maxSkipLevels,
int skipInterval)
|
Method Summary | |
---|---|
void |
close()
|
int |
getDoc()
Returns the id of the doc to which the last call of skipTo(int)
has skipped. |
void |
init(long skipPointer,
int df)
initializes the reader |
protected abstract int |
readSkipData(int level,
IndexInput skipStream)
Subclasses must implement the actual skip data encoding in this method. |
protected void |
seekChild(int level)
Seeks the skip entry on the given level |
protected void |
setLastSkipData(int level)
Copies the values of the last read skip entry on this level |
int |
skipTo(int target)
Skips entries to the first beyond the current whose document number is greater than or equal to target. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int maxNumberOfSkipLevels
Constructor Detail |
---|
public MultiLevelSkipListReader(IndexInput skipStream, int maxSkipLevels, int skipInterval)
Method Detail |
---|
public int getDoc()
skipTo(int)
has skipped.
public int skipTo(int target) throws IOException
IOException
protected void seekChild(int level) throws IOException
IOException
public void close() throws IOException
IOException
public void init(long skipPointer, int df)
protected abstract int readSkipData(int level, IndexInput skipStream) throws IOException
level
- the level skip data shall be read fromskipStream
- the skip stream to read from
IOException
protected void setLastSkipData(int level)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |