public class DocsFreqBlockIndexInput.DocsFreqBlockReader extends BlockIndexInput.BlockReader
BlockReader
for the .doc file.
Read and decode blocks containing the document identifiers and the node
frequencies. It also decodes the pointers of the associated
blocks from the .nod and .pos files and updates the specified
Index
s.
Modifier and Type | Field and Description |
---|---|
protected int |
blockSize |
in
Modifier and Type | Method and Description |
---|---|
int |
getFirstDocId()
Return the first document identifier of the current block.
|
int |
getLastDocId()
Return the last document identifier of the current block.
|
protected void |
initBlock()
Init reader for new block
|
boolean |
isExhausted() |
int |
nextDocument()
Decode and return the next document identifier of the current block.
|
int |
nextNodeFreq()
Decode and return the next node frequency of the current block.
|
protected void |
readHeader()
Read and decode block header
|
void |
setNodeBlockIndex(BlockIndexInput.Index index)
Set the
Index of the NodBlockIndexInput . |
void |
setPosBlockIndex(BlockIndexInput.Index index)
Set the
Index of the PosBlockIndexInput . |
protected void |
skipData()
Skip remaining data in the block and advance input stream pointer.
|
getMinimumBufferSize, init, nextBlock, seek
public void setNodeBlockIndex(BlockIndexInput.Index index) throws IOException
Index
of the NodBlockIndexInput
. The
Index
is used to update the current file pointer of the
NodBlockIndexInput
when decoding a block.IOException
public void setPosBlockIndex(BlockIndexInput.Index index) throws IOException
Index
of the PosBlockIndexInput
. The
Index
is used to update the current file pointer of the
PosBlockIndexInput
when decoding a block.IOException
protected void readHeader() throws IOException
BlockIndexInput.BlockReader
readHeader
in class BlockIndexInput.BlockReader
IOException
protected void skipData()
BlockIndexInput.BlockReader
skipData
in class BlockIndexInput.BlockReader
public int getFirstDocId()
public int getLastDocId()
public int nextDocument() throws IOException
IOException
public int nextNodeFreq() throws IOException
IOException
public boolean isExhausted()
isExhausted
in class BlockIndexInput.BlockReader
protected void initBlock()
BlockIndexInput.BlockReader
initBlock
in class BlockIndexInput.BlockReader
Copyright © 2014. All rights reserved.