Module org.apache.lucene.core
Class Lucene90LiveDocsFormat
- java.lang.Object
-
- org.apache.lucene.codecs.LiveDocsFormat
-
- org.apache.lucene.codecs.lucene90.Lucene90LiveDocsFormat
-
public final class Lucene90LiveDocsFormat extends LiveDocsFormat
Lucene 9.0 live docs formatThe .liv file is optional, and only exists when a segment contains deletions.
Although per-segment, this file is maintained exterior to compound segment files.
Deletions (.liv) --> IndexHeader,Generation,Bits
- SegmentHeader -->
IndexHeader
- Bits --> <
Int64
> LongCount
- SegmentHeader -->
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.String
CODEC_NAME
codec of live docsprivate static java.lang.String
EXTENSION
extension of live docsprivate static int
VERSION_CURRENT
private static int
VERSION_START
supported version range
-
Constructor Summary
Constructors Constructor Description Lucene90LiveDocsFormat()
Sole constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
files(SegmentCommitInfo info, java.util.Collection<java.lang.String> files)
Records all files in use by thisSegmentCommitInfo
into the files argument.private FixedBitSet
readFixedBitSet(IndexInput input, int length)
Bits
readLiveDocs(Directory dir, SegmentCommitInfo info, IOContext context)
Read live docs bits.private int
writeBits(IndexOutput output, Bits bits)
void
writeLiveDocs(Bits bits, Directory dir, SegmentCommitInfo info, int newDelCount, IOContext context)
Persist live docs bits.
-
-
-
Field Detail
-
EXTENSION
private static final java.lang.String EXTENSION
extension of live docs- See Also:
- Constant Field Values
-
CODEC_NAME
private static final java.lang.String CODEC_NAME
codec of live docs- See Also:
- Constant Field Values
-
VERSION_START
private static final int VERSION_START
supported version range- See Also:
- Constant Field Values
-
VERSION_CURRENT
private static final int VERSION_CURRENT
- See Also:
- Constant Field Values
-
-
Method Detail
-
readLiveDocs
public Bits readLiveDocs(Directory dir, SegmentCommitInfo info, IOContext context) throws java.io.IOException
Description copied from class:LiveDocsFormat
Read live docs bits.- Specified by:
readLiveDocs
in classLiveDocsFormat
- Throws:
java.io.IOException
-
readFixedBitSet
private FixedBitSet readFixedBitSet(IndexInput input, int length) throws java.io.IOException
- Throws:
java.io.IOException
-
writeLiveDocs
public void writeLiveDocs(Bits bits, Directory dir, SegmentCommitInfo info, int newDelCount, IOContext context) throws java.io.IOException
Description copied from class:LiveDocsFormat
Persist live docs bits. UseSegmentCommitInfo.getNextDelGen()
to determine the generation of the deletes file you should write to.- Specified by:
writeLiveDocs
in classLiveDocsFormat
- Throws:
java.io.IOException
-
writeBits
private int writeBits(IndexOutput output, Bits bits) throws java.io.IOException
- Throws:
java.io.IOException
-
files
public void files(SegmentCommitInfo info, java.util.Collection<java.lang.String> files) throws java.io.IOException
Description copied from class:LiveDocsFormat
Records all files in use by thisSegmentCommitInfo
into the files argument.- Specified by:
files
in classLiveDocsFormat
- Throws:
java.io.IOException
-
-