Class SimpleTextDocValuesReader
- java.lang.Object
-
- org.apache.lucene.codecs.DocValuesProducer
-
- org.apache.lucene.codecs.simpletext.SimpleTextDocValuesReader
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
class SimpleTextDocValuesReader extends DocValuesProducer
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classSimpleTextDocValuesReader.DocValuesIterator(package private) static classSimpleTextDocValuesReader.OneField
-
Field Summary
Fields Modifier and Type Field Description (package private) IndexInputdata(package private) java.util.Map<java.lang.String,SimpleTextDocValuesReader.OneField>fields(package private) intmaxDoc(package private) BytesRefBuilderscratch
-
Constructor Summary
Constructors Constructor Description SimpleTextDocValuesReader(SegmentReadState state, java.lang.String ext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckIntegrity()Checks consistency of this producervoidclose()BinaryDocValuesgetBinary(FieldInfo fieldInfo)ReturnsBinaryDocValuesfor this field.private SimpleTextDocValuesReader.DocValuesIteratorgetBinaryDocsWithField(FieldInfo fieldInfo)NumericDocValuesgetNumeric(FieldInfo fieldInfo)ReturnsNumericDocValuesfor this field.private SimpleTextDocValuesReader.DocValuesIteratorgetNumericDocsWithField(FieldInfo fieldInfo)(package private) java.util.function.IntFunction<java.lang.Long>getNumericNonIterator(FieldInfo fieldInfo)SortedDocValuesgetSorted(FieldInfo fieldInfo)ReturnsSortedDocValuesfor this field.SortedNumericDocValuesgetSortedNumeric(FieldInfo field)ReturnsSortedNumericDocValuesfor this field.SortedSetDocValuesgetSortedSet(FieldInfo fieldInfo)ReturnsSortedSetDocValuesfor this field.private voidreadLine()Used only in ctor:private booleanstartsWith(BytesRef prefix)Used only in ctor:private java.lang.StringstripPrefix(BytesRef prefix)Used only in ctor:java.lang.StringtoString()-
Methods inherited from class org.apache.lucene.codecs.DocValuesProducer
getMergeInstance
-
-
-
-
Field Detail
-
maxDoc
final int maxDoc
-
data
final IndexInput data
-
scratch
final BytesRefBuilder scratch
-
fields
final java.util.Map<java.lang.String,SimpleTextDocValuesReader.OneField> fields
-
-
Constructor Detail
-
SimpleTextDocValuesReader
public SimpleTextDocValuesReader(SegmentReadState state, java.lang.String ext) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
getNumeric
public NumericDocValues getNumeric(FieldInfo fieldInfo) 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. The behavior is undefined if the doc values type of the given field is notDocValuesType.NUMERIC. The return value is nevernull.- Specified by:
getNumericin classDocValuesProducer- Throws:
java.io.IOException
-
getNumericNonIterator
java.util.function.IntFunction<java.lang.Long> getNumericNonIterator(FieldInfo fieldInfo) throws java.io.IOException
- Throws:
java.io.IOException
-
getNumericDocsWithField
private SimpleTextDocValuesReader.DocValuesIterator getNumericDocsWithField(FieldInfo fieldInfo) throws java.io.IOException
- Throws:
java.io.IOException
-
getBinary
public BinaryDocValues getBinary(FieldInfo fieldInfo) 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. The behavior is undefined if the doc values type of the given field is notDocValuesType.BINARY. The return value is nevernull.- Specified by:
getBinaryin classDocValuesProducer- Throws:
java.io.IOException
-
getBinaryDocsWithField
private SimpleTextDocValuesReader.DocValuesIterator getBinaryDocsWithField(FieldInfo fieldInfo) throws java.io.IOException
- Throws:
java.io.IOException
-
getSorted
public SortedDocValues getSorted(FieldInfo fieldInfo) 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. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED. The return value is nevernull.- Specified by:
getSortedin classDocValuesProducer- 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. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED_NUMERIC. The return value is nevernull.- Specified by:
getSortedNumericin classDocValuesProducer- Throws:
java.io.IOException
-
getSortedSet
public SortedSetDocValues getSortedSet(FieldInfo fieldInfo) 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. The behavior is undefined if the doc values type of the given field is notDocValuesType.SORTED_SET. The return value is nevernull.- Specified by:
getSortedSetin classDocValuesProducer- Throws:
java.io.IOException
-
close
public void close() throws java.io.IOException- Throws:
java.io.IOException
-
readLine
private void readLine() throws java.io.IOExceptionUsed only in ctor:- Throws:
java.io.IOException
-
startsWith
private boolean startsWith(BytesRef prefix)
Used only in ctor:
-
stripPrefix
private java.lang.String stripPrefix(BytesRef prefix)
Used only in ctor:
-
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
-
-