Module org.apache.lucene.codecs
Class SimpleTextSkipWriter
java.lang.Object
org.apache.lucene.codecs.MultiLevelSkipListWriter
org.apache.lucene.codecs.simpletext.SimpleTextSkipWriter
plain text skip data.
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final int(package private) static final BytesRefprivate CompetitiveImpactAccumulator[]private intprivate long(package private) static final BytesRef(package private) static final BytesRef(package private) static final BytesRef(package private) static final BytesRef(package private) static final BytesRef(package private) static final BytesRef(package private) static final int(package private) static final BytesRefprivate final BytesRefBuilder(package private) static final BytesRef(package private) static final BytesRef(package private) static final BytesRef(package private) static final intFields inherited from class org.apache.lucene.codecs.MultiLevelSkipListWriter
numberOfSkipLevels -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) voidbufferSkip(int doc, long docFilePointer, int numDocs, CompetitiveImpactAccumulator competitiveImpactAccumulator) protected voidCreates new buffers or empties the existing onesprotected voidwriteChildPointer(long childPointer, DataOutput skipBuffer) Writes the child pointer of a block to the given output.protected voidwriteLevelLength(long levelLength, IndexOutput output) Writes the length of a level to the given output.longwriteSkip(IndexOutput output) Writes the buffered skip lists to the given output.protected voidwriteSkipData(int level, DataOutput skipBuffer) Subclasses must implement the actual skip data encoding in this method.Methods inherited from class org.apache.lucene.codecs.MultiLevelSkipListWriter
bufferSkip, init
-
Field Details
-
skipMultiplier
static final int skipMultiplier- See Also:
-
maxSkipLevels
static final int maxSkipLevels- See Also:
-
BLOCK_SIZE
static final int BLOCK_SIZE- See Also:
-
wroteHeaderPerLevelMap
-
curDoc
private int curDoc -
curDocFilePointer
private long curDocFilePointer -
curCompetitiveFreqNorms
-
scratch
-
SKIP_LIST
-
LEVEL_LENGTH
-
LEVEL
-
SKIP_DOC
-
SKIP_DOC_FP
-
IMPACTS
-
IMPACT
-
FREQ
-
NORM
-
IMPACTS_END
-
CHILD_POINTER
-
-
Constructor Details
-
SimpleTextSkipWriter
SimpleTextSkipWriter(SegmentWriteState writeState) throws IOException - Throws:
IOException
-
-
Method Details
-
writeSkipData
Description copied from class:MultiLevelSkipListWriterSubclasses must implement the actual skip data encoding in this method.- Specified by:
writeSkipDatain classMultiLevelSkipListWriter- Parameters:
level- the level skip data shall be writing forskipBuffer- the skip buffer to write to- Throws:
IOException
-
resetSkip
protected void resetSkip()Description copied from class:MultiLevelSkipListWriterCreates new buffers or empties the existing ones- Overrides:
resetSkipin classMultiLevelSkipListWriter
-
writeSkip
Description copied from class:MultiLevelSkipListWriterWrites the buffered skip lists to the given output.- Overrides:
writeSkipin classMultiLevelSkipListWriter- Parameters:
output- the IndexOutput the skip lists shall be written to- Returns:
- the pointer the skip list starts
- Throws:
IOException
-
bufferSkip
void bufferSkip(int doc, long docFilePointer, int numDocs, CompetitiveImpactAccumulator competitiveImpactAccumulator) throws IOException - Throws:
IOException
-
writeLevelLength
Description copied from class:MultiLevelSkipListWriterWrites the length of a level to the given output.- Overrides:
writeLevelLengthin classMultiLevelSkipListWriter- Parameters:
levelLength- the length of a leveloutput- the IndexOutput the length shall be written to- Throws:
IOException
-
writeChildPointer
Description copied from class:MultiLevelSkipListWriterWrites the child pointer of a block to the given output.- Overrides:
writeChildPointerin classMultiLevelSkipListWriter- Parameters:
childPointer- block of higher level point to the lower levelskipBuffer- the skip buffer to write to- Throws:
IOException
-