Package org.apache.lucene.codecs.memory
Class DirectDocValuesProducer
- java.lang.Object
-
- org.apache.lucene.codecs.DocValuesProducer
-
- org.apache.lucene.codecs.memory.DirectDocValuesProducer
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable,Accountable
class DirectDocValuesProducer extends DocValuesProducer
Reader forDirectDocValuesFormat
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classDirectDocValuesProducer.BinaryEntry(package private) static classDirectDocValuesProducer.BinaryRawValues(package private) static classDirectDocValuesProducer.FSTEntry(package private) static classDirectDocValuesProducer.NumericEntry(package private) static classDirectDocValuesProducer.NumericRawValues(package private) static classDirectDocValuesProducer.SortedEntry(package private) static classDirectDocValuesProducer.SortedNumericEntry(package private) static classDirectDocValuesProducer.SortedNumericRawValues(package private) static classDirectDocValuesProducer.SortedRawValues(package private) static classDirectDocValuesProducer.SortedSetEntry(package private) static classDirectDocValuesProducer.SortedSetRawValues
-
Field Summary
Fields Modifier and Type Field Description private java.util.Map<java.lang.String,DirectDocValuesProducer.BinaryEntry>binariesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.BinaryRawValues>binaryInstances(package private) static byteBYTESprivate IndexInputdataprivate java.util.Map<java.lang.String,FixedBitSet>docsWithFieldInstancesprivate intmaxDocprivate booleanmerging(package private) static byteNUMBERprivate intnumEntriesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.NumericRawValues>numericInstancesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.NumericEntry>numericsprivate java.util.concurrent.atomic.AtomicLongramBytesUsed(package private) static byteSORTED(package private) static byteSORTED_NUMERIC(package private) static byteSORTED_NUMERIC_SINGLETON(package private) static byteSORTED_SET(package private) static byteSORTED_SET_SINGLETONprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedRawValues>sortedInstancesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedNumericRawValues>sortedNumericInstancesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedNumericEntry>sortedNumericsprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedEntry>sortedsprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedSetRawValues>sortedSetInstancesprivate java.util.Map<java.lang.String,DirectDocValuesProducer.SortedSetEntry>sortedSetsprivate intversion(package private) static intVERSION_CURRENT(package private) static intVERSION_START-
Fields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLE
-
-
Constructor Summary
Constructors Constructor Description DirectDocValuesProducer(DirectDocValuesProducer original)DirectDocValuesProducer(SegmentReadState state, java.lang.String dataCodec, java.lang.String dataExtension, java.lang.String metaCodec, java.lang.String metaExtension)
-
Method Summary
-
-
-
Field Detail
-
numerics
private final java.util.Map<java.lang.String,DirectDocValuesProducer.NumericEntry> numerics
-
binaries
private final java.util.Map<java.lang.String,DirectDocValuesProducer.BinaryEntry> binaries
-
sorteds
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedEntry> sorteds
-
sortedSets
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedSetEntry> sortedSets
-
sortedNumerics
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedNumericEntry> sortedNumerics
-
data
private final IndexInput data
-
numericInstances
private final java.util.Map<java.lang.String,DirectDocValuesProducer.NumericRawValues> numericInstances
-
binaryInstances
private final java.util.Map<java.lang.String,DirectDocValuesProducer.BinaryRawValues> binaryInstances
-
sortedInstances
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedRawValues> sortedInstances
-
sortedSetInstances
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedSetRawValues> sortedSetInstances
-
sortedNumericInstances
private final java.util.Map<java.lang.String,DirectDocValuesProducer.SortedNumericRawValues> sortedNumericInstances
-
docsWithFieldInstances
private final java.util.Map<java.lang.String,FixedBitSet> docsWithFieldInstances
-
numEntries
private final int numEntries
-
maxDoc
private final int maxDoc
-
ramBytesUsed
private final java.util.concurrent.atomic.AtomicLong ramBytesUsed
-
version
private final int version
-
merging
private final boolean merging
-
NUMBER
static final byte NUMBER
- See Also:
- Constant Field Values
-
BYTES
static final byte BYTES
- See Also:
- Constant Field Values
-
SORTED
static final byte SORTED
- See Also:
- Constant Field Values
-
SORTED_SET
static final byte SORTED_SET
- See Also:
- Constant Field Values
-
SORTED_SET_SINGLETON
static final byte SORTED_SET_SINGLETON
- See Also:
- Constant Field Values
-
SORTED_NUMERIC
static final byte SORTED_NUMERIC
- See Also:
- Constant Field Values
-
SORTED_NUMERIC_SINGLETON
static final byte SORTED_NUMERIC_SINGLETON
- See Also:
- Constant Field Values
-
VERSION_START
static final int VERSION_START
- See Also:
- Constant Field Values
-
VERSION_CURRENT
static final int VERSION_CURRENT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
DirectDocValuesProducer
DirectDocValuesProducer(DirectDocValuesProducer original)
-
DirectDocValuesProducer
DirectDocValuesProducer(SegmentReadState state, java.lang.String dataCodec, java.lang.String dataExtension, java.lang.String metaCodec, java.lang.String metaExtension) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
readNumericEntry
private DirectDocValuesProducer.NumericEntry readNumericEntry(IndexInput meta) throws java.io.IOException
- Throws:
java.io.IOException
-
readBinaryEntry
private DirectDocValuesProducer.BinaryEntry readBinaryEntry(IndexInput meta) throws java.io.IOException
- Throws:
java.io.IOException
-
readSortedEntry
private DirectDocValuesProducer.SortedEntry readSortedEntry(IndexInput meta) throws java.io.IOException
- Throws:
java.io.IOException
-
readSortedSetEntry
private DirectDocValuesProducer.SortedSetEntry readSortedSetEntry(IndexInput meta, boolean singleton) throws java.io.IOException
- Throws:
java.io.IOException
-
readSortedNumericEntry
private DirectDocValuesProducer.SortedNumericEntry readSortedNumericEntry(IndexInput meta, boolean singleton) throws java.io.IOException
- Throws:
java.io.IOException
-
readFields
private int readFields(IndexInput meta, FieldInfos infos) throws java.io.IOException
- Throws:
java.io.IOException
-
ramBytesUsed
public long ramBytesUsed()
Description copied from interface:AccountableReturn the memory usage of this object in bytes. Negative values are illegal.
-
getChildResources
public java.util.Collection<Accountable> getChildResources()
Description copied from interface:AccountableReturns nested resources of this class. The result should be a point-in-time snapshot (to avoid race conditions).- See Also:
Accountables
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
checkIntegrity
public void checkIntegrity() throws java.io.IOExceptionDescription copied from class:DocValuesProducerChecks 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.
- Specified by:
checkIntegrityin classDocValuesProducer- Throws:
java.io.IOException
-
getNumeric
public NumericDocValues getNumeric(FieldInfo field) throws java.io.IOException
Description copied from class:DocValuesProducerReturnsNumericDocValuesfor this field. The returned instance need not be thread-safe: it will only be used by a single thread.- Specified by:
getNumericin classDocValuesProducer- Throws:
java.io.IOException
-
loadNumeric
private DirectDocValuesProducer.NumericRawValues loadNumeric(DirectDocValuesProducer.NumericEntry entry) throws java.io.IOException
- Throws:
java.io.IOException
-
getLegacyBinary
private LegacyBinaryDocValues getLegacyBinary(FieldInfo field) throws java.io.IOException
- Throws:
java.io.IOException
-
getBinary
public BinaryDocValues getBinary(FieldInfo field) throws java.io.IOException
Description copied from class:DocValuesProducerReturnsBinaryDocValuesfor this field. The returned instance need not be thread-safe: it will only be used by a single thread.- Specified by:
getBinaryin classDocValuesProducer- Throws:
java.io.IOException
-
loadBinary
private DirectDocValuesProducer.BinaryRawValues loadBinary(DirectDocValuesProducer.BinaryEntry entry) throws java.io.IOException
- Throws:
java.io.IOException
-
getSorted
public SortedDocValues getSorted(FieldInfo field) throws java.io.IOException
Description copied from class:DocValuesProducerReturnsSortedDocValuesfor this field. The returned instance need not be thread-safe: it will only be used by a single thread.- Specified by:
getSortedin classDocValuesProducer- Throws:
java.io.IOException
-
newSortedInstance
private LegacySortedDocValues newSortedInstance(LegacyNumericDocValues docToOrd, LegacyBinaryDocValues values, int count)
-
loadSorted
private DirectDocValuesProducer.SortedRawValues loadSorted(FieldInfo field) throws java.io.IOException
- Throws:
java.io.IOException
-
getSortedNumeric
public SortedNumericDocValues getSortedNumeric(FieldInfo field) throws java.io.IOException
Description copied from class:DocValuesProducerReturnsSortedNumericDocValuesfor this field. The returned instance need not be thread-safe: it will only be used by a single thread.- Specified by:
getSortedNumericin classDocValuesProducer- Throws:
java.io.IOException
-
loadSortedNumeric
private DirectDocValuesProducer.SortedNumericRawValues loadSortedNumeric(DirectDocValuesProducer.SortedNumericEntry entry) throws java.io.IOException
- Throws:
java.io.IOException
-
getSortedSet
public SortedSetDocValues getSortedSet(FieldInfo field) throws java.io.IOException
Description copied from class:DocValuesProducerReturnsSortedSetDocValuesfor this field. The returned instance need not be thread-safe: it will only be used by a single thread.- Specified by:
getSortedSetin classDocValuesProducer- Throws:
java.io.IOException
-
loadSortedSet
private DirectDocValuesProducer.SortedSetRawValues loadSortedSet(DirectDocValuesProducer.SortedSetEntry entry) throws java.io.IOException
- Throws:
java.io.IOException
-
getMissingBits
private Bits getMissingBits(FieldInfo field, long offset, long length) throws java.io.IOException
- Throws:
java.io.IOException
-
getMergeInstance
public DocValuesProducer getMergeInstance()
Description copied from class:DocValuesProducerReturns an instance optimized for merging. This instance may only be consumed in the thread that calledDocValuesProducer.getMergeInstance().The default implementation returns
this- Overrides:
getMergeInstancein classDocValuesProducer
-
close
public void close() throws java.io.IOException- Throws:
java.io.IOException
-
-