Class Lucene62Codec
- java.lang.Object
-
- org.apache.lucene.codecs.Codec
-
- org.apache.lucene.codecs.lucene62.Lucene62Codec
-
- All Implemented Interfaces:
NamedSPILoader.NamedSPI
public class Lucene62Codec extends Codec
Implements the Lucene 6.2 index format, with configurable per-field postings and docvalues formats.If you want to reuse functionality of this codec in another codec, extend
FilterCodec.- See Also:
package documentation for file format details.- WARNING: This API is experimental and might change in incompatible ways in the next release.
-
-
Constructor Summary
Constructors Constructor Description Lucene62Codec()Instantiates a new codec.Lucene62Codec(Lucene50StoredFieldsFormat.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 CompoundFormatcompoundFormat()DocValuesFormatdocValuesFormat()FieldInfosFormatfieldInfosFormat()DocValuesFormatgetDocValuesFormatForField(String field)Returns the docvalues format that should be used for writing new segments offield.PostingsFormatgetPostingsFormatForField(String field)Returns the postings format that should be used for writing new segments offield.LiveDocsFormatliveDocsFormat()NormsFormatnormsFormat()PointsFormatpointsFormat()PostingsFormatpostingsFormat()SegmentInfoFormatsegmentInfoFormat()StoredFieldsFormatstoredFieldsFormat()TermVectorsFormattermVectorsFormat()-
Methods inherited from class org.apache.lucene.codecs.Codec
availableCodecs, forName, getDefault, getName, reloadCodecs, setDefault, toString
-
-
-
-
Constructor Detail
-
Lucene62Codec
public Lucene62Codec()
Instantiates a new codec.
-
Lucene62Codec
public Lucene62Codec(Lucene50StoredFieldsFormat.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:
storedFieldsFormatin classCodec
-
termVectorsFormat
public final TermVectorsFormat termVectorsFormat()
- Specified by:
termVectorsFormatin classCodec
-
postingsFormat
public final PostingsFormat postingsFormat()
- Specified by:
postingsFormatin classCodec
-
fieldInfosFormat
public final FieldInfosFormat fieldInfosFormat()
- Specified by:
fieldInfosFormatin classCodec
-
segmentInfoFormat
public SegmentInfoFormat segmentInfoFormat()
- Specified by:
segmentInfoFormatin classCodec
-
liveDocsFormat
public final LiveDocsFormat liveDocsFormat()
- Specified by:
liveDocsFormatin classCodec
-
compoundFormat
public final CompoundFormat compoundFormat()
- Specified by:
compoundFormatin classCodec
-
pointsFormat
public final PointsFormat pointsFormat()
- Specified by:
pointsFormatin 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 "Lucene50".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 "Lucene54".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:
docValuesFormatin classCodec
-
normsFormat
public NormsFormat normsFormat()
- Specified by:
normsFormatin classCodec
-
-