public static class STBlockLine.Serializer extends BlockLine.Serializer
This class extends BlockLine.Serializer,
so it keeps a state of the previous term read to decode the next term.
currentTerm| Constructor and Description |
|---|
Serializer() |
| Modifier and Type | Method and Description |
|---|---|
static int[] |
readFieldIds(DataInput termStatesInput,
int numFields)
Reads all the field ids in the current block line of the provided input.
|
static void |
readFieldTermStatesMap(DataInput termStatesInput,
DeltaBaseTermStateSerializer termStateSerializer,
BlockHeader blockHeader,
FieldInfos fieldInfos,
Map<String,BlockTermState> fieldTermStatesMap)
Reads all the
BlockTermState of all the field in the current block line of the provided input. |
static BlockTermState |
readTermStateForField(int fieldId,
DataInput termStatesInput,
DeltaBaseTermStateSerializer termStateSerializer,
BlockHeader blockHeader,
FieldInfos fieldInfos,
BlockTermState reuse)
Reads a single
BlockTermState for the provided field in the current block line of the provided input. |
static void |
writeLineTermStates(DataOutput termStatesOutput,
STBlockLine line,
DeltaBaseTermStateSerializer encoder)
Writes all the
BlockTermState of the provided STBlockLine to the given output. |
numBitsToEncode, ramBytesUsed, readBytes, readIncrementallyEncodedTerm, readLine, writeIncrementallyEncodedTerm, writeLine, writeLineTermStateclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetChildResourcespublic static void writeLineTermStates(DataOutput termStatesOutput, STBlockLine line, DeltaBaseTermStateSerializer encoder) throws IOException
BlockTermState of the provided STBlockLine to the given output.IOExceptionpublic static BlockTermState readTermStateForField(int fieldId, DataInput termStatesInput, DeltaBaseTermStateSerializer termStateSerializer, BlockHeader blockHeader, FieldInfos fieldInfos, BlockTermState reuse) throws IOException
BlockTermState for the provided field in the current block line of the provided input.termStatesInput - Data input to read the BlockTermState from.blockHeader - Current block header.reuse - A previous BlockTermState to reuse; or null to create a new one.BlockTermState corresponding to the provided field id; or null if the field
does not occur in the line.IOExceptionpublic static void readFieldTermStatesMap(DataInput termStatesInput, DeltaBaseTermStateSerializer termStateSerializer, BlockHeader blockHeader, FieldInfos fieldInfos, Map<String,BlockTermState> fieldTermStatesMap) throws IOException
BlockTermState of all the field in the current block line of the provided input.fieldTermStatesMap - Map filled with the term states for each field. It is cleared first.IOExceptionreadTermStateForField(int, org.apache.lucene.store.DataInput, org.apache.lucene.codecs.uniformsplit.DeltaBaseTermStateSerializer, org.apache.lucene.codecs.uniformsplit.BlockHeader, org.apache.lucene.index.FieldInfos, org.apache.lucene.codecs.BlockTermState)public static int[] readFieldIds(DataInput termStatesInput, int numFields) throws IOException
IOExceptionCopyright © 2000-2019 Apache Software Foundation. All Rights Reserved.