Package org.apache.lucene.codecs
Class DocValuesProducer
java.lang.Object
org.apache.lucene.codecs.DocValuesProducer
- All Implemented Interfaces:
Closeable
,AutoCloseable
- Direct Known Subclasses:
EmptyDocValuesProducer
Abstract API that produces numeric, binary, sorted, sortedset, and sortednumeric docvalues.
- WARNING: This API is experimental and might change in incompatible ways in the next release.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract void
Checks consistency of this producerabstract BinaryDocValues
ReturnsBinaryDocValues
for this field.Returns an instance optimized for merging.abstract NumericDocValues
getNumeric
(FieldInfo field) ReturnsNumericDocValues
for this field.abstract SortedDocValues
ReturnsSortedDocValues
for this field.abstract SortedNumericDocValues
getSortedNumeric
(FieldInfo field) ReturnsSortedNumericDocValues
for this field.abstract SortedSetDocValues
getSortedSet
(FieldInfo field) ReturnsSortedSetDocValues
for this field.
-
Constructor Details
-
DocValuesProducer
protected DocValuesProducer()Sole constructor. (For invocation by subclass constructors, typically implicit.)
-
-
Method Details
-
getNumeric
ReturnsNumericDocValues
for this field. The returned instance need not be thread-safe: it will only be used by a single thread. The behavior is undefined if the doc values type of the given field is notDocValuesType.NUMERIC
. The return value is nevernull
.- Throws:
IOException
-
getBinary
ReturnsBinaryDocValues
for this field. The returned instance need not be thread-safe: it will only be used by a single thread. The behavior is undefined if the doc values type of the given field is notDocValuesType.BINARY
. The return value is nevernull
.- Throws:
IOException
-
getSorted
ReturnsSortedDocValues
for this field. The returned instance need not be thread-safe: it will only be used by a single thread. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED
. The return value is nevernull
.- Throws:
IOException
-
getSortedNumeric
ReturnsSortedNumericDocValues
for this field. The returned instance need not be thread-safe: it will only be used by a single thread. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED_NUMERIC
. The return value is nevernull
.- Throws:
IOException
-
getSortedSet
ReturnsSortedSetDocValues
for this field. The returned instance need not be thread-safe: it will only be used by a single thread. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED_SET
. The return value is nevernull
.- Throws:
IOException
-
checkIntegrity
Checks consistency of this producerNote that this may be costly in terms of I/O, e.g. may involve computing a checksum value against large data files.
- Throws:
IOException
- NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.
-
getMergeInstance
Returns an instance optimized for merging. This instance may only be consumed in the thread that calledgetMergeInstance()
.The default implementation returns
this
-