Class Lucene91Codec
- java.lang.Object
-
- org.apache.lucene.codecs.Codec
-
- org.apache.lucene.backward_codecs.lucene91.Lucene91Codec
-
- All Implemented Interfaces:
NamedSPILoader.NamedSPI
public class Lucene91Codec extends Codec
Implements the Lucene 9.1 index formatIf you want to reuse functionality of this codec in another codec, extend
FilterCodec
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Lucene91Codec.Mode
Configuration option for the codec.
-
Constructor Summary
Constructors Constructor Description Lucene91Codec()
Instantiates a new codec.Lucene91Codec(Lucene91Codec.Mode mode)
Instantiates a new codec, specifying the stored fields compression mode to use.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CompoundFormat
compoundFormat()
DocValuesFormat
docValuesFormat()
FieldInfosFormat
fieldInfosFormat()
DocValuesFormat
getDocValuesFormatForField(String field)
Returns the docvalues format that should be used for writing new segments offield
.KnnVectorsFormat
getKnnVectorsFormatForField(String field)
Returns the vectors format that should be used for writing new segments offield
PostingsFormat
getPostingsFormatForField(String field)
Returns the postings format that should be used for writing new segments offield
.KnnVectorsFormat
knnVectorsFormat()
LiveDocsFormat
liveDocsFormat()
NormsFormat
normsFormat()
PointsFormat
pointsFormat()
PostingsFormat
postingsFormat()
SegmentInfoFormat
segmentInfoFormat()
StoredFieldsFormat
storedFieldsFormat()
TermVectorsFormat
termVectorsFormat()
-
Methods inherited from class org.apache.lucene.codecs.Codec
availableCodecs, forName, getDefault, getName, reloadCodecs, setDefault, toString
-
-
-
-
Constructor Detail
-
Lucene91Codec
public Lucene91Codec()
Instantiates a new codec.
-
Lucene91Codec
public Lucene91Codec(Lucene91Codec.Mode mode)
Instantiates a new codec, specifying the stored fields compression mode to use.- Parameters:
mode
- stored fields compression mode to use for newly flushed/merged segments.
-
-
Method Detail
-
storedFieldsFormat
public final StoredFieldsFormat storedFieldsFormat()
- Specified by:
storedFieldsFormat
in classCodec
-
termVectorsFormat
public final TermVectorsFormat termVectorsFormat()
- Specified by:
termVectorsFormat
in classCodec
-
postingsFormat
public final PostingsFormat postingsFormat()
- Specified by:
postingsFormat
in classCodec
-
fieldInfosFormat
public final FieldInfosFormat fieldInfosFormat()
- Specified by:
fieldInfosFormat
in classCodec
-
segmentInfoFormat
public SegmentInfoFormat segmentInfoFormat()
- Specified by:
segmentInfoFormat
in classCodec
-
liveDocsFormat
public final LiveDocsFormat liveDocsFormat()
- Specified by:
liveDocsFormat
in classCodec
-
compoundFormat
public final CompoundFormat compoundFormat()
- Specified by:
compoundFormat
in classCodec
-
pointsFormat
public final PointsFormat pointsFormat()
- Specified by:
pointsFormat
in classCodec
-
knnVectorsFormat
public KnnVectorsFormat knnVectorsFormat()
- Specified by:
knnVectorsFormat
in classCodec
-
getPostingsFormatForField
public PostingsFormat getPostingsFormatForField(String field)
Returns the postings format that should be used for writing new segments offield
.The default implementation always returns "Lucene90".
WARNING: if you subclass, you are responsible for index backwards compatibility: future version of Lucene are only guaranteed to be able to read the default implementation,
-
getDocValuesFormatForField
public DocValuesFormat getDocValuesFormatForField(String field)
Returns the docvalues format that should be used for writing new segments offield
.The default implementation always returns "Lucene90".
WARNING: if you subclass, you are responsible for index backwards compatibility: future version of Lucene are only guaranteed to be able to read the default implementation.
-
getKnnVectorsFormatForField
public KnnVectorsFormat getKnnVectorsFormatForField(String field)
Returns the vectors format that should be used for writing new segments offield
The default implementation always returns "Lucene91".
WARNING: if you subclass, you are responsible for index backwards compatibility: future version of Lucene are only guaranteed to be able to read the default implementation.
-
docValuesFormat
public final DocValuesFormat docValuesFormat()
- Specified by:
docValuesFormat
in classCodec
-
normsFormat
public final NormsFormat normsFormat()
- Specified by:
normsFormat
in classCodec
-
-