Uses of Class
org.apache.lucene.index.LeafReader
Packages that use LeafReader
Package
Description
The logical representation of a
Document for indexing and
searching.Code to maintain and access indices.
High-performance single-document main memory Apache Lucene fulltext search index.
Misc index tools and index support.
Monitoring framework
A variety of functions to use with FunctionQuery.
This package contains a flexible graph-based proximity query, TermAutomatonQuery, and geospatial
queries.
Code to search indices.
Highlighting search terms.
Support for index-time and query-time joins.
This package contains several components useful to build a highlighter on top of the
Matches API.Support for document suggestion
The UnifiedHighlighter -- a flexible highlighter that can get offsets from postings, term
vectors, or analysis.
-
Uses of LeafReader in org.apache.lucene.document
Methods in org.apache.lucene.document with parameters of type LeafReaderModifier and TypeMethodDescriptionprivate ScorerSpatialQuery.RelationScorerSupplier.getContainsDenseScorer(LeafReader reader, Weight weight, float boost, ScoreMode scoreMode) private ScorerSpatialQuery.RelationScorerSupplier.getDenseScorer(LeafReader reader, Weight weight, float boost, ScoreMode scoreMode) Scorer used for WITHIN and DISJOINTprotected ScorerSpatialQuery.RelationScorerSupplier.getScorer(LeafReader reader, Weight weight, float boost, ScoreMode scoreMode) protected ScorerSupplierBaseShapeDocValuesQuery.getScorerSupplier(LeafReader reader, SpatialQuery.SpatialVisitor spatialVisitor, ScoreMode scoreMode, ConstantScoreWeight weight, float boost, float score) protected ScorerSupplierSpatialQuery.getScorerSupplier(LeafReader reader, SpatialQuery.SpatialVisitor spatialVisitor, ScoreMode scoreMode, ConstantScoreWeight weight, float boost, float score) private ScorerSpatialQuery.RelationScorerSupplier.getSparseScorer(LeafReader reader, Weight weight, float boost, ScoreMode scoreMode) Scorer used for INTERSECTS and single value pointsprivate BinaryRangeDocValuesBinaryRangeFieldRangeQuery.getValues(LeafReader reader, String field) -
Uses of LeafReader in org.apache.lucene.index
Subclasses of LeafReader in org.apache.lucene.indexModifier and TypeClassDescriptionclassLeafReader implemented by codec APIs.(package private) classstatic classWrapper class for another FilterAtomicReader.classAFilterCodecReadercontains another CodecReader, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.classAFilterLeafReadercontains another LeafReader, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.classAnLeafReaderwhich reads multiple, parallel indexes.final classIndexReader implementation over a single segment.(package private) final classA mergedCodecReaderview of multipleCodecReader.(package private) static final class(package private) static final classfinal classAnCodecReaderwhich supports sorting documents by a givenSort.Fields in org.apache.lucene.index declared as LeafReaderModifier and TypeFieldDescriptionprotected final LeafReaderFilterLeafReader.inThe underlying LeafReader.private final LeafReader[]ParallelLeafReader.parallelReadersprivate final LeafReaderLeafReaderContext.readerprivate final LeafReaderSoftDeletesDirectoryReaderWrapper.SoftDeletesFilterCodecReader.readerprivate final LeafReaderSoftDeletesDirectoryReaderWrapper.SoftDeletesFilterLeafReader.readerprivate final LeafReader[]ParallelLeafReader.storedFieldsReadersFields in org.apache.lucene.index with type parameters of type LeafReaderModifier and TypeFieldDescriptionprivate final Set<LeafReader> ParallelLeafReader.completeReaderSetprivate final SortedMap<String, LeafReader> ParallelLeafReader.fieldToReaderprotected Comparator<LeafReader> LiveIndexWriterConfig.leafSorterThe comparator for sorting leaf readers.private final Map<IndexReader.CacheKey, LeafReader> SoftDeletesDirectoryReaderWrapper.SoftDeletesSubReaderWrapper.mappingprivate final Map<String, LeafReader> ParallelLeafReader.termsFieldToReaderprivate final SortedMap<String, LeafReader> ParallelLeafReader.tvFieldToReaderMethods in org.apache.lucene.index that return LeafReaderModifier and TypeMethodDescriptionFilterLeafReader.getDelegate()Returns the wrappedLeafReader.private LeafReaderIndexingChain.getDocValuesLeafReader()ParallelLeafReader.getParallelReaders()Returns theLeafReaders that were passed on init.private static LeafReader[]ParallelCompositeReader.prepareLeafReaders(CompositeReader[] readers, CompositeReader[] storedFieldsReaders) LeafReaderContext.reader()static LeafReaderFilterLeafReader.unwrap(LeafReader reader) Get the wrapped instance byreaderas long as this reader is an instance ofFilterLeafReader.ExitableDirectoryReader.ExitableSubReaderWrapper.wrap(LeafReader reader) protected LeafReader[]FilterDirectoryReader.SubReaderWrapper.wrap(List<? extends LeafReader> readers) Wraps a list of LeafReadersabstract LeafReaderFilterDirectoryReader.SubReaderWrapper.wrap(LeafReader reader) Wrap one of the parent DirectoryReader's subreadersprotected LeafReader[]SoftDeletesDirectoryReaderWrapper.SoftDeletesSubReaderWrapper.wrap(List<? extends LeafReader> readers) SoftDeletesDirectoryReaderWrapper.SoftDeletesSubReaderWrapper.wrap(LeafReader reader) (package private) static LeafReaderSoftDeletesDirectoryReaderWrapper.wrap(LeafReader reader, String field) Methods in org.apache.lucene.index that return types with arguments of type LeafReaderModifier and TypeMethodDescriptionLiveIndexWriterConfig.getLeafSorter()Returns a comparator for sorting leaf readers.Methods in org.apache.lucene.index with parameters of type LeafReaderModifier and TypeMethodDescriptionprivate static booleanSoftDeletesDirectoryReaderWrapper.assertDocCounts(int expectedNumDocs, int numSoftDeletes, LeafReader reader) static voidByteVectorValues.checkField(LeafReader in, String field) Checks the Vector Encoding of a fieldprivate static voidDocValues.checkField(LeafReader in, String field, DocValuesType... expected) static voidFloatVectorValues.checkField(LeafReader in, String field) Checks the Vector Encoding of a fieldIndexSorter.NumericDocValuesProvider.get(LeafReader reader) Returns the NumericDocValues instance for this LeafReaderIndexSorter.SortedDocValuesProvider.get(LeafReader reader) Returns the SortedDocValues instance for this LeafReaderstatic BinaryDocValuesDocValues.getBinary(LeafReader reader, String field) Returns BinaryDocValues for the field, orDocValues.emptyBinary()if it has none.IndexSorter.DoubleSorter.getDocComparator(LeafReader reader, int maxDoc) IndexSorter.FloatSorter.getDocComparator(LeafReader reader, int maxDoc) IndexSorter.getDocComparator(LeafReader reader, int maxDoc) Get a comparator that determines the sort order of docs within a single Reader.IndexSorter.IntSorter.getDocComparator(LeafReader reader, int maxDoc) IndexSorter.LongSorter.getDocComparator(LeafReader reader, int maxDoc) IndexSorter.StringSorter.getDocComparator(LeafReader reader, int maxDoc) static NumericDocValuesDocValues.getNumeric(LeafReader reader, String field) Returns NumericDocValues for the field, orDocValues.emptyNumeric()if it has none.static SortedDocValuesDocValues.getSorted(LeafReader reader, String field) Returns SortedDocValues for the field, orDocValues.emptySorted()if it has none.static SortedNumericDocValuesDocValues.getSortedNumeric(LeafReader reader, String field) Returns SortedNumericDocValues for the field, orDocValues.emptySortedNumeric()if it has none.static SortedSetDocValuesDocValues.getSortedSet(LeafReader reader, String field) Returns SortedSetDocValues for the field, orDocValues.emptySortedSet()if it has none.static TermsTerms.getTerms(LeafReader reader, String field) Returns theTermsindex for this field, orTerms.EMPTYif it has none.private static PointsReaderSlowCodecReaderWrapper.pointValuesToReader(LeafReader reader) private static DocValuesProducerSlowCodecReaderWrapper.readerToDocValuesProducer(LeafReader reader) private static FieldsProducerSlowCodecReaderWrapper.readerToFieldsProducer(LeafReader reader) private static NormsProducerSlowCodecReaderWrapper.readerToNormsProducer(LeafReader reader) private static StoredFieldsReaderSlowCodecReaderWrapper.readerToStoredFieldsReader(LeafReader reader) private static TermVectorsReaderSlowCodecReaderWrapper.readerToTermVectorsReader(LeafReader reader) private static KnnVectorsReaderSlowCodecReaderWrapper.readerToVectorReader(LeafReader reader) (package private) Sorter.DocMapSorter.sort(LeafReader reader) Returns a mapping from the old document ID to its new location in the sorted index.static LeafReaderFilterLeafReader.unwrap(LeafReader reader) Get the wrapped instance byreaderas long as this reader is an instance ofFilterLeafReader.voidIndexWriter.IndexReaderWarmer.warm(LeafReader reader) Invoked on theLeafReaderfor the newly merged segment, before that segment is made visible to near-real-time readers.voidSimpleMergedSegmentWarmer.warm(LeafReader reader) ExitableDirectoryReader.ExitableSubReaderWrapper.wrap(LeafReader reader) abstract LeafReaderFilterDirectoryReader.SubReaderWrapper.wrap(LeafReader reader) Wrap one of the parent DirectoryReader's subreadersstatic CodecReaderSlowCodecReaderWrapper.wrap(LeafReader reader) Returns aCodecReaderview of reader.SoftDeletesDirectoryReaderWrapper.SoftDeletesSubReaderWrapper.wrap(LeafReader reader) (package private) static LeafReaderSoftDeletesDirectoryReaderWrapper.wrap(LeafReader reader, String field) Method parameters in org.apache.lucene.index with type arguments of type LeafReaderModifier and TypeMethodDescriptionIndexSorter.DoubleSorter.getComparableProviders(List<? extends LeafReader> readers) IndexSorter.FloatSorter.getComparableProviders(List<? extends LeafReader> readers) IndexSorter.getComparableProviders(List<? extends LeafReader> readers) Get an array ofIndexSorter.ComparableProvider, one per segment, for merge sorting documents in different segmentsIndexSorter.IntSorter.getComparableProviders(List<? extends LeafReader> readers) IndexSorter.LongSorter.getComparableProviders(List<? extends LeafReader> readers) IndexSorter.StringSorter.getComparableProviders(List<? extends LeafReader> readers) static DirectoryReaderDirectoryReader.open(IndexCommit commit, int minSupportedMajorVersion, Comparator<LeafReader> leafSorter) Expert: returns an IndexReader reading the index on the givenIndexCommit.static DirectoryReaderDirectoryReader.open(Directory directory, Comparator<LeafReader> leafSorter) Returns a IndexReader for the the index in the given Directory(package private) static DirectoryReaderStandardDirectoryReader.open(Directory directory, int minSupportedMajorVersion, IndexCommit commit, Comparator<LeafReader> leafSorter) called from DirectoryReader.open(...) methods(package private) static DirectoryReaderStandardDirectoryReader.open(Directory directory, IndexCommit commit, Comparator<LeafReader> leafSorter) static DirectoryReaderStandardDirectoryReader.open(Directory directory, SegmentInfos infos, List<? extends LeafReader> oldReaders, Comparator<LeafReader> leafSorter) This constructor is only used forStandardDirectoryReader.doOpenIfChanged(SegmentInfos), as well as NRT replication.static DirectoryReaderStandardDirectoryReader.open(Directory directory, SegmentInfos infos, List<? extends LeafReader> oldReaders, Comparator<LeafReader> leafSorter) This constructor is only used forStandardDirectoryReader.doOpenIfChanged(SegmentInfos), as well as NRT replication.IndexWriterConfig.setLeafSorter(Comparator<LeafReader> leafSorter) Set the comparator for sorting leaf readers.protected LeafReader[]FilterDirectoryReader.SubReaderWrapper.wrap(List<? extends LeafReader> readers) Wraps a list of LeafReadersprotected LeafReader[]SoftDeletesDirectoryReaderWrapper.SoftDeletesSubReaderWrapper.wrap(List<? extends LeafReader> readers) Constructors in org.apache.lucene.index with parameters of type LeafReaderModifierConstructorDescriptionprotectedDirectoryReader(Directory directory, LeafReader[] segmentReaders, Comparator<LeafReader> leafSorter) Expert: Constructs aDirectoryReaderon the given subReaders.ExitableFilterAtomicReader(LeafReader in, QueryTimeout queryTimeout) Constructor *protectedConstruct a FilterLeafReader based on the specified base reader.(package private)LeafReaderContext(CompositeReaderContext parent, LeafReader reader, int ord, int docBase, int leafOrd, int leafDocBase) Creates a newLeafReaderContext(package private)LeafReaderContext(LeafReader leafReader) ParallelLeafReader(boolean closeSubReaders, LeafReader... readers) Create a ParallelLeafReader based on the provided readers.ParallelLeafReader(boolean closeSubReaders, LeafReader[] readers, LeafReader[] storedFieldsReaders) Expert: create a ParallelLeafReader based on the provided readers and storedFieldReaders; when a document is loaded, only storedFieldsReaders will be used.ParallelLeafReader(LeafReader... readers) Create a ParallelLeafReader based on the provided readers; auto-closes the given readers onIndexReader.close().privateSoftDeletesFilterLeafReader(LeafReader reader, FixedBitSet bits, int numDocs) (package private)StandardDirectoryReader(Directory directory, LeafReader[] readers, IndexWriter writer, SegmentInfos sis, Comparator<LeafReader> leafSorter, boolean applyAllDeletes, boolean writeAllDeletes) package private constructor, called only from static open() methods.(package private)TermDocsIterator(LeafReader reader, boolean sortedTerms) Constructor parameters in org.apache.lucene.index with type arguments of type LeafReaderModifierConstructorDescriptionprotectedDirectoryReader(Directory directory, LeafReader[] segmentReaders, Comparator<LeafReader> leafSorter) Expert: Constructs aDirectoryReaderon the given subReaders.SoftDeletesSubReaderWrapper(Map<IndexReader.CacheKey, LeafReader> oldReadersCache, String field) (package private)StandardDirectoryReader(Directory directory, LeafReader[] readers, IndexWriter writer, SegmentInfos sis, Comparator<LeafReader> leafSorter, boolean applyAllDeletes, boolean writeAllDeletes) package private constructor, called only from static open() methods. -
Uses of LeafReader in org.apache.lucene.index.memory
Subclasses of LeafReader in org.apache.lucene.index.memoryModifier and TypeClassDescriptionprivate final classSearch support for Lucene framework integration; implements all methods required by the Lucene IndexReader contracts. -
Uses of LeafReader in org.apache.lucene.misc.index
Subclasses of LeafReader in org.apache.lucene.misc.indexModifier and TypeClassDescriptionprivate static classprivate static final classprivate static class -
Uses of LeafReader in org.apache.lucene.monitor
Fields in org.apache.lucene.monitor declared as LeafReaderModifier and TypeFieldDescriptionprivate final LeafReaderDocumentBatch.MultiDocumentBatch.readerprivate final LeafReaderDocumentBatch.SingletonDocumentBatch.readerMethods in org.apache.lucene.monitor that return LeafReaderModifier and TypeMethodDescriptionprivate LeafReaderDocumentBatch.MultiDocumentBatch.build(IndexWriter writer, Document... docs) DocumentBatch.MultiDocumentBatch.get()DocumentBatch.SingletonDocumentBatch.get()Methods in org.apache.lucene.monitor with parameters of type LeafReaderModifier and TypeMethodDescriptionprivate QueryTermFilteredPresearcher.buildFilterClause(LeafReader reader, String field) private QueryTermFilteredPresearcher.buildFilterFields(LeafReader reader) abstract QueryPresearcher.buildQuery(LeafReader reader, BiPredicate<String, BytesRef> termAcceptor) Build a query for a Monitor's queryindex from a LeafReader over a set of documents to monitor.final QueryTermFilteredPresearcher.buildQuery(LeafReader reader, BiPredicate<String, BytesRef> termAcceptor) -
Uses of LeafReader in org.apache.lucene.queries.function.valuesource
Methods in org.apache.lucene.queries.function.valuesource with parameters of type LeafReaderModifier and TypeMethodDescription(package private) static voidVectorFieldFunction.checkField(LeafReader in, String field, VectorEncoding expectedEncoding) Checks the Vector Encoding of a field -
Uses of LeafReader in org.apache.lucene.sandbox.search
Constructors in org.apache.lucene.sandbox.search with parameters of type LeafReaderModifierConstructorDescription(package private)MultiNormsLeafSimScorer(Similarity.SimScorer scorer, LeafReader reader, Collection<CombinedFieldQuery.FieldAndWeight> normFields, boolean needsScores) Sole constructor: Score documents ofreaderwithscorer. -
Uses of LeafReader in org.apache.lucene.search
Methods in org.apache.lucene.search with parameters of type LeafReaderModifier and TypeMethodDescriptionstatic DocIdSetIteratorFieldExistsQuery.getDocValuesDocIdSetIterator(String field, LeafReader reader) Returns aDocIdSetIteratorfrom the given field or null if the field doesn't exist in the reader or if the reader has no doc values for the field.private NumericDocValuesSortedNumericSortField.getValue(LeafReader reader) private SortedDocValuesSortedSetSortField.getValues(LeafReader reader) private static booleanPhraseQuery.termNotInReader(LeafReader reader, Term term) private booleanTermQuery.TermWeight.termNotInReader(LeafReader reader, Term term) Constructors in org.apache.lucene.search with parameters of type LeafReaderModifierConstructorDescriptionLeafSimScorer(Similarity.SimScorer scorer, LeafReader reader, String field, boolean needsScores) Sole constructor: Score documents ofreaderwithscorer. -
Uses of LeafReader in org.apache.lucene.search.highlight
Subclasses of LeafReader in org.apache.lucene.search.highlightModifier and TypeClassDescriptionclassWraps a Terms with aLeafReader, typically from term vectors.(package private) static final classFields in org.apache.lucene.search.highlight declared as LeafReaderConstructors in org.apache.lucene.search.highlight with parameters of type LeafReader -
Uses of LeafReader in org.apache.lucene.search.join
Methods in org.apache.lucene.search.join with parameters of type LeafReader -
Uses of LeafReader in org.apache.lucene.search.matchhighlight
Fields in org.apache.lucene.search.matchhighlight declared as LeafReaderMethods in org.apache.lucene.search.matchhighlight with parameters of type LeafReaderModifier and TypeMethodDescriptionvoidMatchRegionRetriever.MatchOffsetsConsumer.accept(int docId, LeafReader leafReader, int leafDocId, Map<String, List<OffsetRange>> hits) Constructors in org.apache.lucene.search.matchhighlight with parameters of type LeafReaderModifierConstructorDescription(package private)DocHit(int docId, LeafReader leafReader, int leafDocId) -
Uses of LeafReader in org.apache.lucene.search.suggest.document
Fields in org.apache.lucene.search.suggest.document declared as LeafReaderConstructors in org.apache.lucene.search.suggest.document with parameters of type LeafReaderModifierConstructorDescriptionprotectedCompletionScorer(CompletionWeight weight, NRTSuggester suggester, LeafReader reader, Bits filterDocs, boolean filtered, Automaton automaton) Creates a scorer for a field-specificsuggesterscoped byacceptDocs -
Uses of LeafReader in org.apache.lucene.search.uhighlight
Subclasses of LeafReader in org.apache.lucene.search.uhighlightModifier and TypeClassDescriptionclassOverlays a 2nd LeafReader for the terms of one field, otherwise the primary reader is consulted.private static final classNeeded to support the ability to highlight a query irrespective of the field a query refers to (aka requireFieldMatch=false).(package private) final classA filtered LeafReader that only includes the terms that are also in a provided set of terms.private static classWraps an IndexReader that remembers/caches the last call toTermVectors.get(int)so that if the next call has the same ID, then it is reused.Fields in org.apache.lucene.search.uhighlight declared as LeafReaderModifier and TypeFieldDescriptionprivate final LeafReaderOverlaySingleDocTermsLeafReader.in2private final LeafReaderMemoryIndexOffsetStrategy.memIndexLeafReaderMethods in org.apache.lucene.search.uhighlight with parameters of type LeafReaderModifier and TypeMethodDescriptionprotected OffsetsEnumFieldOffsetStrategy.createOffsetsEnumFromReader(LeafReader leafReader, int doc) voidPhraseHelper.createOffsetsEnumsForSpans(LeafReader leafReader, int docId, List<OffsetsEnum> results) Given the internal SpanQueries, produce a number of OffsetsEnum into theresultsparam.protected voidFieldOffsetStrategy.createOffsetsEnumsWeightMatcher(LeafReader _leafReader, int docId, List<OffsetsEnum> results) abstract OffsetsEnumFieldOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) The primary method -- return offsets for highlightable words in the specified document.MemoryIndexOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) MultiFieldsOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) NoOpOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) PostingsOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) PostingsWithTermVectorsOffsetStrategy.getOffsetsEnum(LeafReader leafReader, int docId, String content) TermVectorOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) TokenStreamOffsetStrategy.getOffsetsEnum(LeafReader reader, int docId, String content) FieldHighlighter.highlightFieldForDoc(LeafReader reader, int docId, String content) The primary method -- highlight this doc, assuming a specific field and given this content.Constructors in org.apache.lucene.search.uhighlight with parameters of type LeafReaderModifierConstructorDescriptionOverlaySingleDocTermsLeafReader(LeafReader in, LeafReader in2, String in2Field, int in2TargetDocId) (package private)SingleFieldWithOffsetsFilterLeafReader(LeafReader in, String fieldName) (package private)TermVectorFilteredLeafReader(LeafReader baseLeafReader, Terms filterTerms, String fieldFilter) Construct a FilterLeafReader based on the specified base reader.(package private)