Uses of Class
org.apache.lucene.index.IndexReader
Packages that use IndexReader
Package
Description
Automatically filter high-frequency stopwords.
Uses already seen data (the indexed documents) to classify an input ( can be simple text or a
structured document).
Uses already seen data (the indexed documents) to classify new documents.
Utilities for evaluation, data preparation, etc.
Code to maintain and access indices.
High-performance single-document main memory Apache Lucene fulltext search index.
Miscellaneous Lucene utilities that don't really fit anywhere else.
Misc extensions of the Document/Field API.
Misc index tools and index support.
Monitoring framework
Filters and Queries that add to core Lucene.
Queries that compute score based upon a function.
Document similarity query generators.
The calculus of spans.
This package contains SrndQuery and its subclasses.
Additional queries (some may have caveats or limitations)
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.Suggest alternate spellings for words.
Support for Autocomplete/Autosuggest
Support for document suggestion
The UnifiedHighlighter -- a flexible highlighter that can get offsets from postings, term
vectors, or analysis.
Another highlighter implementation based on term vectors.
-
Uses of IndexReader in org.apache.lucene.analysis.query
Constructors in org.apache.lucene.analysis.query with parameters of type IndexReaderModifierConstructorDescriptionQueryAutoStopWordAnalyzer
(Analyzer delegate, IndexReader indexReader) Creates a new QueryAutoStopWordAnalyzer with stopwords calculated for all indexed fields from terms with a document frequency percentage greater thanQueryAutoStopWordAnalyzer.defaultMaxDocFreqPercent
QueryAutoStopWordAnalyzer
(Analyzer delegate, IndexReader indexReader, float maxPercentDocs) Creates a new QueryAutoStopWordAnalyzer with stopwords calculated for all indexed fields from terms with a document frequency percentage greater than the given maxPercentDocsQueryAutoStopWordAnalyzer
(Analyzer delegate, IndexReader indexReader, int maxDocFreq) Creates a new QueryAutoStopWordAnalyzer with stopwords calculated for all indexed fields from terms with a document frequency greater than the given maxDocFreqQueryAutoStopWordAnalyzer
(Analyzer delegate, IndexReader indexReader, Collection<String> fields, float maxPercentDocs) Creates a new QueryAutoStopWordAnalyzer with stopwords calculated for the given selection of fields from terms with a document frequency percentage greater than the given maxPercentDocsQueryAutoStopWordAnalyzer
(Analyzer delegate, IndexReader indexReader, Collection<String> fields, int maxDocFreq) Creates a new QueryAutoStopWordAnalyzer with stopwords calculated for the given selection of fields from terms with a document frequency greater than the given maxDocFreq -
Uses of IndexReader in org.apache.lucene.classification
Fields in org.apache.lucene.classification declared as IndexReaderModifier and TypeFieldDescriptionprivate final IndexReader
BM25NBClassifier.indexReader
IndexReader
used to access theClassifier
's indexprotected final IndexReader
SimpleNaiveBayesClassifier.indexReader
IndexReader
used to access theClassifier
's indexConstructors in org.apache.lucene.classification with parameters of type IndexReaderModifierConstructorDescriptionBM25NBClassifier
(IndexReader indexReader, Analyzer analyzer, Query query, String classFieldName, String... textFieldNames) Creates a new NaiveBayes classifier.BooleanPerceptronClassifier
(IndexReader indexReader, Analyzer analyzer, Query query, Integer batchSize, Double bias, String classFieldName, String textFieldName) Creates aBooleanPerceptronClassifier
CachingNaiveBayesClassifier
(IndexReader indexReader, Analyzer analyzer, Query query, String classFieldName, String... textFieldNames) Creates a new NaiveBayes classifier with inside caching.KNearestFuzzyClassifier
(IndexReader indexReader, Similarity similarity, Analyzer analyzer, Query query, int k, String classFieldName, String... textFieldNames) Creates aKNearestFuzzyClassifier
.KNearestNeighborClassifier
(IndexReader indexReader, Similarity similarity, Analyzer analyzer, Query query, int k, int minDocsFreq, int minTermFreq, String classFieldName, String... textFieldNames) Creates aKNearestNeighborClassifier
.SimpleNaiveBayesClassifier
(IndexReader indexReader, Analyzer analyzer, Query query, String classFieldName, String... textFieldNames) Creates a new NaiveBayes classifier. -
Uses of IndexReader in org.apache.lucene.classification.document
Constructors in org.apache.lucene.classification.document with parameters of type IndexReaderModifierConstructorDescriptionKNearestNeighborDocumentClassifier
(IndexReader indexReader, Similarity similarity, Query query, int k, int minDocsFreq, int minTermFreq, String classFieldName, Map<String, Analyzer> field2analyzer, String... textFieldNames) Creates aKNearestNeighborClassifier
.SimpleNaiveBayesDocumentClassifier
(IndexReader indexReader, Query query, String classFieldName, Map<String, Analyzer> field2analyzer, String... textFieldNames) Creates a new NaiveBayes classifier. -
Uses of IndexReader in org.apache.lucene.classification.utils
Methods in org.apache.lucene.classification.utils with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate void
NearestFuzzyQuery.addTerms
(IndexReader reader, NearestFuzzyQuery.FieldVals f, NearestFuzzyQuery.ScoreTermQueue q) static <T> ConfusionMatrixGenerator.ConfusionMatrix
ConfusionMatrixGenerator.getConfusionMatrix
(IndexReader reader, Classifier<T> classifier, String classFieldName, String textFieldName, long timeoutMilliseconds) get theConfusionMatrixGenerator.ConfusionMatrix
of a givenClassifier
, generated on the givenIndexReader
, class and text fields.private Query
NearestFuzzyQuery.newTermQuery
(IndexReader reader, Term term) void
DatasetSplitter.split
(IndexReader originalIndex, Directory trainingIndex, Directory testIndex, Directory crossValidationIndex, Analyzer analyzer, boolean termVectors, String classFieldName, String... fieldNames) Split a given index into 3 indexes for training, test and cross validation tasks respectively -
Uses of IndexReader in org.apache.lucene.index
Classes in org.apache.lucene.index with type parameters of type IndexReaderModifier and TypeClassDescriptionclass
BaseCompositeReader<R extends IndexReader>
Base class for implementingCompositeReader
s based on an array of sub-readers.Subclasses of IndexReader in org.apache.lucene.indexModifier and TypeClassDescriptionclass
BaseCompositeReader<R extends IndexReader>
Base class for implementingCompositeReader
s based on an array of sub-readers.class
LeafReader implemented by codec APIs.class
Instances of this reader type can only be used to get stored fields from the underlying LeafReaders, but it is not possible to directly retrieve postings.class
DirectoryReader is an implementation ofCompositeReader
that can read indexes in aDirectory
.(package private) class
class
TheExitableDirectoryReader
wraps a real indexDirectoryReader
and allows for aQueryTimeout
implementation object to be checked periodically to see if the thread should exit or not.static class
Wrapper class for another FilterAtomicReader.class
AFilterCodecReader
contains another CodecReader, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.class
A FilterDirectoryReader wraps another DirectoryReader, allowing implementations to transform or extend it.class
AFilterLeafReader
contains another LeafReader, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.class
LeafReader
is an abstract class, providing an interface for accessing an index.class
ACompositeReader
which reads multiple indexes, appending their content.class
AnCompositeReader
which reads multiple, parallel indexes.class
AnLeafReader
which reads multiple, parallel indexes.final class
IndexReader implementation over a single segment.(package private) final class
A mergedCodecReader
view of multipleCodecReader
.final class
This reader filters out documents that have a doc values value in the given field and treat these documents as soft deleted.(package private) static final class
(package private) static final class
final class
AnCodecReader
which supports sorting documents by a givenSort
.final class
Default implementation ofDirectoryReader
.Fields in org.apache.lucene.index declared as IndexReaderFields in org.apache.lucene.index with type parameters of type IndexReaderModifier and TypeFieldDescriptionprivate final Set
<IndexReader> ParallelCompositeReader.completeReaderSet
private final Set
<IndexReader> IndexReader.parentReaders
Methods in org.apache.lucene.index that return IndexReaderModifier and TypeMethodDescriptionabstract IndexReader
IndexReaderContext.reader()
Returns theIndexReader
, this context represents.Methods in org.apache.lucene.index that return types with arguments of type IndexReaderModifier and TypeMethodDescriptionprotected abstract List
<? extends IndexReader> CompositeReader.getSequentialSubReaders()
Expert: returns the sequential sub readers that this reader is logically composed of.Methods in org.apache.lucene.index with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate IndexReaderContext
CompositeReaderContext.Builder.build
(CompositeReaderContext parent, IndexReader reader, int ord, int docBase) static BinaryDocValues
MultiDocValues.getBinaryValues
(IndexReader r, String field) Returns a BinaryDocValues for a reader's docvalues (potentially merging on-the-fly)static int
PointValues.getDocCount
(IndexReader reader, String field) Return the cumulated number of docs that have points across all leaves of the givenIndexReader
.static Collection
<String> FieldInfos.getIndexedFields
(IndexReader reader) Returns a set of names of fields that have a terms index.static Bits
MultiBits.getLiveDocs
(IndexReader reader) Returns a singleBits
instance for this reader, merging live Documents on the fly.static byte[]
PointValues.getMaxPackedValue
(IndexReader reader, String field) Return the maximum packed values across all leaves of the givenIndexReader
.static FieldInfos
FieldInfos.getMergedFieldInfos
(IndexReader reader) Call this to get the (merged) FieldInfos for a composite reader.static byte[]
PointValues.getMinPackedValue
(IndexReader reader, String field) Return the minimum packed values across all leaves of the givenIndexReader
.static NumericDocValues
MultiDocValues.getNormValues
(IndexReader r, String field) Returns a NumericDocValues for a reader's norms (potentially merging on-the-fly).static NumericDocValues
MultiDocValues.getNumericValues
(IndexReader r, String field) Returns a NumericDocValues for a reader's docvalues (potentially merging on-the-fly)static SortedNumericDocValues
MultiDocValues.getSortedNumericValues
(IndexReader r, String field) Returns a SortedNumericDocValues for a reader's docvalues (potentially merging on-the-fly)static SortedSetDocValues
MultiDocValues.getSortedSetValues
(IndexReader r, String field) Returns a SortedSetDocValues for a reader's docvalues (potentially doing extremely slow things).static SortedDocValues
MultiDocValues.getSortedValues
(IndexReader r, String field) Returns a SortedDocValues for a reader's docvalues (potentially doing extremely slow things).static PostingsEnum
MultiTerms.getTermPostingsEnum
(IndexReader r, String field, BytesRef term) ReturnsPostingsEnum
for the specified field and term.static PostingsEnum
MultiTerms.getTermPostingsEnum
(IndexReader r, String field, BytesRef term, int flags) ReturnsPostingsEnum
for the specified field and term, with control over whether freqs, positions, offsets or payloads are required.static Terms
MultiTerms.getTerms
(IndexReader r, String field) This method may return null if the field does not exist or if it has no terms.final void
IndexReader.registerParentReader
(IndexReader reader) Expert: This method is called byIndexReader
s which wrap other readers (e.g.static long
PointValues.size
(IndexReader reader, String field) Return the cumulated number of points across all leaves of the givenIndexReader
.long
IndexWriter.tryDeleteDocument
(IndexReader readerIn, int docID) Expert: attempts to delete by document ID, as long as the provided reader is a near-real-time reader (fromDirectoryReader.open(IndexWriter)
).private long
IndexWriter.tryModifyDocument
(IndexReader readerIn, int docID, IndexWriter.DocModifier toApply) long
IndexWriter.tryUpdateDocValue
(IndexReader readerIn, int docID, Field... fields) Expert: attempts to update doc values by document ID, as long as the provided reader is a near-real-time reader (fromDirectoryReader.open(IndexWriter)
).Constructors in org.apache.lucene.index with parameters of type IndexReaderModifierConstructorDescriptionprotected
BaseCompositeReader
(R[] subReaders, Comparator<R> subReadersSorter) Constructs aBaseCompositeReader
on the given subReaders.MultiReader
(IndexReader... subReaders) Construct a MultiReader aggregating the named set of (sub)readers.MultiReader
(IndexReader[] subReaders, boolean closeSubReaders) Construct a MultiReader aggregating the named set of (sub)readers.MultiReader
(IndexReader[] subReaders, Comparator<IndexReader> subReadersSorter, boolean closeSubReaders) Construct a MultiReader aggregating the named set of (sub)readers.Constructor parameters in org.apache.lucene.index with type arguments of type IndexReaderModifierConstructorDescriptionMultiReader
(IndexReader[] subReaders, Comparator<IndexReader> subReadersSorter, boolean closeSubReaders) Construct a MultiReader aggregating the named set of (sub)readers. -
Uses of IndexReader in org.apache.lucene.index.memory
Subclasses of IndexReader in org.apache.lucene.index.memoryModifier and TypeClassDescriptionprivate final class
Search support for Lucene framework integration; implements all methods required by the Lucene IndexReader contracts. -
Uses of IndexReader in org.apache.lucene.misc
Methods in org.apache.lucene.misc with parameters of type IndexReaderModifier and TypeMethodDescriptionstatic TermStats[]
HighFreqTerms.getHighFreqTerms
(IndexReader reader, int numTerms, String field, Comparator<TermStats> comparator) Returns TermStats[] ordered by the specified comparator -
Uses of IndexReader in org.apache.lucene.misc.document
Fields in org.apache.lucene.misc.document declared as IndexReaderConstructors in org.apache.lucene.misc.document with parameters of type IndexReader -
Uses of IndexReader in org.apache.lucene.misc.index
Subclasses of IndexReader in org.apache.lucene.misc.indexModifier and TypeClassDescriptionprivate static class
private static final class
This class emulates deletions on the underlying index.private static final class
private static class
Methods in org.apache.lucene.misc.index with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate static void
IndexRearranger.addOneSegment
(IndexWriter writer, IndexReader reader, IndexRearranger.DocumentSelector selector) private static MultiPassIndexSplitter.FakeDeleteLeafIndexReader[]
MultiPassIndexSplitter.FakeDeleteIndexReader.initSubReaders
(IndexReader reader) void
MultiPassIndexSplitter.split
(IndexReader in, Directory[] outputs, boolean seq) Split source index into multiple parts.Constructors in org.apache.lucene.misc.index with parameters of type IndexReader -
Uses of IndexReader in org.apache.lucene.monitor
Methods in org.apache.lucene.monitor with parameters of type IndexReaderModifier and TypeMethodDescriptionTermsHashBuilder.newSearcher
(IndexReader reader, IndexReader previousReader) Constructors in org.apache.lucene.monitor with parameters of type IndexReader -
Uses of IndexReader in org.apache.lucene.queries
Methods in org.apache.lucene.queries with parameters of type IndexReaderModifier and TypeMethodDescriptionvoid
CommonTermsQuery.collectTermStates
(IndexReader reader, List<LeafReaderContext> leaves, TermStates[] contextArray, Term[] queryTerms) -
Uses of IndexReader in org.apache.lucene.queries.function
Fields in org.apache.lucene.queries.function declared as IndexReaderModifier and TypeFieldDescription(package private) final IndexReader
FunctionQuery.AllScorer.reader
Methods in org.apache.lucene.queries.function with parameters of type IndexReaderModifier and TypeMethodDescriptiondouble
IndexReaderFunctions.ReaderFunction.apply
(IndexReader reader) -
Uses of IndexReader in org.apache.lucene.queries.mlt
Fields in org.apache.lucene.queries.mlt declared as IndexReaderConstructors in org.apache.lucene.queries.mlt with parameters of type IndexReaderModifierConstructorDescriptionConstructor requiring an IndexReader.MoreLikeThis
(IndexReader ir, TFIDFSimilarity sim) -
Uses of IndexReader in org.apache.lucene.queries.spans
Methods in org.apache.lucene.queries.spans with parameters of type IndexReaderModifier and TypeMethodDescriptionabstract SpanQuery
SpanMultiTermQueryWrapper.SpanRewriteMethod.rewrite
(IndexReader reader, MultiTermQuery query) SpanMultiTermQueryWrapper.TopTermsSpanBooleanQueryRewrite.rewrite
(IndexReader reader, MultiTermQuery query) -
Uses of IndexReader in org.apache.lucene.queryparser.surround.query
Fields in org.apache.lucene.queryparser.surround.query declared as IndexReaderMethods in org.apache.lucene.queryparser.surround.query that return IndexReaderMethods in org.apache.lucene.queryparser.surround.query with parameters of type IndexReaderModifier and TypeMethodDescriptionDistanceQuery.getSpanNearQuery
(IndexReader reader, String fieldName, BasicQueryFactory qf) abstract void
SimpleTerm.visitMatchingTerms
(IndexReader reader, String fieldName, SimpleTerm.MatchingTermVisitor mtv) void
SrndPrefixQuery.visitMatchingTerms
(IndexReader reader, String fieldName, SimpleTerm.MatchingTermVisitor mtv) void
SrndTermQuery.visitMatchingTerms
(IndexReader reader, String fieldName, SimpleTerm.MatchingTermVisitor mtv) void
SrndTruncQuery.visitMatchingTerms
(IndexReader reader, String fieldName, SimpleTerm.MatchingTermVisitor mtv) Constructors in org.apache.lucene.queryparser.surround.query with parameters of type IndexReaderModifierConstructorDescriptionSpanNearClauseFactory
(IndexReader reader, String fieldName, BasicQueryFactory qf) -
Uses of IndexReader in org.apache.lucene.sandbox.queries
Methods in org.apache.lucene.sandbox.queries with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate void
FuzzyLikeThisQuery.addTerms
(IndexReader reader, FuzzyLikeThisQuery.FieldVals f, FuzzyLikeThisQuery.ScoreTermQueue q) private Query
FuzzyLikeThisQuery.newTermQuery
(IndexReader reader, Term term) -
Uses of IndexReader in org.apache.lucene.sandbox.search
Methods in org.apache.lucene.sandbox.search with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate void
CombinedFieldQuery.validateConsistentNorms
(IndexReader reader) Constructors in org.apache.lucene.sandbox.search with parameters of type IndexReader -
Uses of IndexReader in org.apache.lucene.search
Fields in org.apache.lucene.search declared as IndexReaderMethods in org.apache.lucene.search that return IndexReaderModifier and TypeMethodDescriptionIndexSearcher.getIndexReader()
Return theIndexReader
this searches.Methods in org.apache.lucene.search with parameters of type IndexReaderModifier and TypeMethodDescription(package private) final void
TermCollectingRewrite.collectTerms
(IndexReader reader, MultiTermQuery query, TermCollectingRewrite.TermCollector collector) private Query
AbstractKnnVectorQuery.createRewrittenQuery
(IndexReader reader, TopDocs topK) (package private) static int[]
AbstractKnnVectorQuery.findSegmentStarts
(IndexReader reader, int[] docs) static IndexSearcher
SearcherManager.getSearcher
(SearcherFactory searcherFactory, IndexReader reader, IndexReader previousReader) Expert: creates a searcher from the providedIndexReader
using the providedSearcherFactory
.SearcherFactory.newSearcher
(IndexReader reader, IndexReader previousReader) Returns a new IndexSearcher over the given reader.DocValuesRewriteMethod.rewrite
(IndexReader reader, MultiTermQuery query) abstract Query
MultiTermQuery.RewriteMethod.rewrite
(IndexReader reader, MultiTermQuery query) Query.rewrite
(IndexReader reader) Deprecated.final Query
ScoringRewrite.rewrite
(IndexReader reader, MultiTermQuery query) final Query
TopTermsRewrite.rewrite
(IndexReader reader, MultiTermQuery query) Constructors in org.apache.lucene.search with parameters of type IndexReaderModifierConstructorDescriptionCreates a searcher searching the provided index.IndexSearcher
(IndexReader r, Executor executor) Runs searches for each segment separately, using the provided Executor. -
Uses of IndexReader in org.apache.lucene.search.highlight
Subclasses of IndexReader in org.apache.lucene.search.highlightModifier and TypeClassDescriptionclass
Wraps a Terms with aLeafReader
, typically from term vectors.(package private) static final class
Fields in org.apache.lucene.search.highlight declared as IndexReaderMethods in org.apache.lucene.search.highlight with parameters of type IndexReaderModifier and TypeMethodDescriptionstatic TokenStream
TokenSources.getAnyTokenStream
(IndexReader reader, int docId, String field, Analyzer analyzer) Deprecated.static TokenStream
TokenSources.getAnyTokenStream
(IndexReader reader, int docId, String field, Document document, Analyzer analyzer) Deprecated.static final WeightedTerm[]
QueryTermExtractor.getIdfWeightedTerms
(Query query, IndexReader reader, String fieldName) Extracts all terms texts of a given Query into an array of WeightedTermsstatic TokenStream
TokenSources.getTokenStream
(IndexReader reader, int docId, String field, Analyzer analyzer) Deprecated.static TokenStream
TokenSources.getTokenStreamWithOffsets
(IndexReader reader, int docId, String field) Deprecated.WeightedSpanTermExtractor.getWeightedSpanTermsWithScores
(Query query, float boost, TokenStream tokenStream, String fieldName, IndexReader reader) Creates a Map ofWeightedSpanTerms
from the givenQuery
andTokenStream
.private void
QueryScorer.init
(Query query, String field, IndexReader reader, boolean expandMultiTermQuery) Constructors in org.apache.lucene.search.highlight with parameters of type IndexReaderModifierConstructorDescriptionQueryScorer
(Query query, IndexReader reader, String field) QueryScorer
(Query query, IndexReader reader, String field, String defaultField) QueryTermScorer
(Query query, IndexReader reader, String fieldName) -
Uses of IndexReader in org.apache.lucene.search.join
Methods in org.apache.lucene.search.join with parameters of type IndexReaderModifier and TypeMethodDescriptionstatic void
CheckJoinIndex.check
(IndexReader reader, BitSetProducer parentsFilter) Check that the given index is good to use for block joins. -
Uses of IndexReader in org.apache.lucene.search.matchhighlight
Methods in org.apache.lucene.search.matchhighlight with parameters of type IndexReaderModifier and TypeMethodDescriptionMatchRegionRetriever.computeOffsetRetrievalStrategies
(IndexReader reader, Analyzer analyzer) Compute default strategies for retrieving offsets fromMatchesIterator
instances for a set of given fields. -
Uses of IndexReader in org.apache.lucene.search.spell
Fields in org.apache.lucene.search.spell declared as IndexReaderModifier and TypeFieldDescriptionprivate IndexReader
HighFrequencyDictionary.reader
private IndexReader
LuceneDictionary.reader
Methods in org.apache.lucene.search.spell with parameters of type IndexReaderModifier and TypeMethodDescriptionprivate int
WordBreakSpellChecker.generateBreakUpSuggestions
(Term term, IndexReader ir, int numberBreaks, int maxSuggestions, int useMinSuggestionFrequency, SuggestWord[] prefix, Queue<WordBreakSpellChecker.SuggestWordArrayWrapper> suggestions, int totalEvaluations, WordBreakSpellChecker.BreakSuggestionSortMethod sortMethod) private SuggestWord
WordBreakSpellChecker.generateSuggestWord
(IndexReader ir, String fieldname, String text) DirectSpellChecker.suggestSimilar
(Term term, int numSug, IndexReader ir) protected Collection
<DirectSpellChecker.ScoreTerm> DirectSpellChecker.suggestSimilar
(Term term, int numSug, IndexReader ir, int docfreq, int editDistance, float accuracy, CharsRefBuilder spare) Provide spelling corrections based on several parameters.DirectSpellChecker.suggestSimilar
(Term term, int numSug, IndexReader ir, SuggestMode suggestMode) DirectSpellChecker.suggestSimilar
(Term term, int numSug, IndexReader ir, SuggestMode suggestMode, float accuracy) Suggest similar words.String[]
SpellChecker.suggestSimilar
(String word, int numSug, IndexReader ir, String field, SuggestMode suggestMode) String[]
SpellChecker.suggestSimilar
(String word, int numSug, IndexReader ir, String field, SuggestMode suggestMode, float accuracy) Suggest similar words (optionally restricted to a field of an index).SuggestWord[][]
WordBreakSpellChecker.suggestWordBreaks
(Term term, int maxSuggestions, IndexReader ir, SuggestMode suggestMode, WordBreakSpellChecker.BreakSuggestionSortMethod sortMethod) Generate suggestions by breaking the passed-in term into multiple words.WordBreakSpellChecker.suggestWordCombinations
(Term[] terms, int maxSuggestions, IndexReader ir, SuggestMode suggestMode) Generate suggestions by combining one or more of the passed-in terms into single words.Constructors in org.apache.lucene.search.spell with parameters of type IndexReaderModifierConstructorDescriptionHighFrequencyDictionary
(IndexReader reader, String field, float thresh) Creates a new Dictionary, pulling source terms from the specifiedfield
in the providedreader
.LuceneDictionary
(IndexReader reader, String field) Creates a new Dictionary, pulling source terms from the specifiedfield
in the providedreader
-
Uses of IndexReader in org.apache.lucene.search.suggest
Fields in org.apache.lucene.search.suggest declared as IndexReaderModifier and TypeFieldDescriptionprotected final IndexReader
DocumentDictionary.reader
IndexReader
to load documents fromConstructors in org.apache.lucene.search.suggest with parameters of type IndexReaderModifierConstructorDescriptionDocumentDictionary
(IndexReader reader, String field, String weightField) Creates a new dictionary with the contents of the fields namedfield
for the terms andweightField
for the weights that will be used for the corresponding terms.DocumentDictionary
(IndexReader reader, String field, String weightField, String payloadField) Creates a new dictionary with the contents of the fields namedfield
for the terms,weightField
for the weights that will be used for the the corresponding terms andpayloadField
for the corresponding payloads for the entry.DocumentDictionary
(IndexReader reader, String field, String weightField, String payloadField, String contextsField) Creates a new dictionary with the contents of the fields namedfield
for the terms,weightField
for the weights that will be used for the the corresponding terms,payloadField
for the corresponding payloads for the entry andcontextsField
for associated contexts.DocumentValueSourceDictionary
(IndexReader reader, String field, LongValuesSource weightsValueSource) Creates a new dictionary with the contents of the fields namedfield
for the terms and uses theweightsValueSource
supplied to determine the score.DocumentValueSourceDictionary
(IndexReader reader, String field, LongValuesSource weightsValueSource, String payload) Creates a new dictionary with the contents of the fields namedfield
for the terms,payloadField
for the corresponding payloads and uses theweightsValueSource
supplied to determine the score.DocumentValueSourceDictionary
(IndexReader reader, String field, LongValuesSource weightsValueSource, String payload, String contexts) Creates a new dictionary with the contents of the fields namedfield
for the terms,payload
for the corresponding payloads,contexts
for the associated contexts and uses theweightsValueSource
supplied to determine the score. -
Uses of IndexReader in org.apache.lucene.search.suggest.document
Constructors in org.apache.lucene.search.suggest.document with parameters of type IndexReaderModifierConstructorDescriptionSuggestIndexSearcher
(IndexReader reader) Creates a searcher with document suggest capabilities forreader
. -
Uses of IndexReader in org.apache.lucene.search.uhighlight
Subclasses of IndexReader in org.apache.lucene.search.uhighlightModifier and TypeClassDescriptionclass
Overlays a 2nd LeafReader for the terms of one field, otherwise the primary reader is consulted.private static final class
Needed to support the ability to highlight a query irrespective of the field a query refers to (aka requireFieldMatch=false).(package private) final class
A filtered LeafReader that only includes the terms that are also in a provided set of terms.private static class
Wraps 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.Methods in org.apache.lucene.search.uhighlight that return IndexReaderModifier and TypeMethodDescription(package private) static IndexReader
UnifiedHighlighter.TermVectorReusingLeafReader.wrap
(IndexReader reader) Methods in org.apache.lucene.search.uhighlight with parameters of type IndexReaderModifier and TypeMethodDescription(package private) static IndexReader
UnifiedHighlighter.TermVectorReusingLeafReader.wrap
(IndexReader reader) -
Uses of IndexReader in org.apache.lucene.search.vectorhighlight
Methods in org.apache.lucene.search.vectorhighlight with parameters of type IndexReaderModifier and TypeMethodDescription(package private) void
FieldQuery.QueryPhraseMap.add
(Query query, IndexReader reader) BaseFragmentsBuilder.createFragment
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList) BaseFragmentsBuilder.createFragment
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, String[] preTags, String[] postTags, Encoder encoder) FragmentsBuilder.createFragment
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList) create a fragment.FragmentsBuilder.createFragment
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, String[] preTags, String[] postTags, Encoder encoder) create a fragment.String[]
BaseFragmentsBuilder.createFragments
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, int maxNumFragments) String[]
BaseFragmentsBuilder.createFragments
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, int maxNumFragments, String[] preTags, String[] postTags, Encoder encoder) String[]
FragmentsBuilder.createFragments
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, int maxNumFragments) create multiple fragments.String[]
FragmentsBuilder.createFragments
(IndexReader reader, int docId, String fieldName, FieldFragList fieldFragList, int maxNumFragments, String[] preTags, String[] postTags, Encoder encoder) create multiple fragments.final String
FastVectorHighlighter.getBestFragment
(FieldQuery fieldQuery, IndexReader reader, int docId, String fieldName, int fragCharSize) return the best fragment.final String
FastVectorHighlighter.getBestFragment
(FieldQuery fieldQuery, IndexReader reader, int docId, String fieldName, int fragCharSize, FragListBuilder fragListBuilder, FragmentsBuilder fragmentsBuilder, String[] preTags, String[] postTags, Encoder encoder) return the best fragment.final String[]
FastVectorHighlighter.getBestFragments
(FieldQuery fieldQuery, IndexReader reader, int docId, String fieldName, int fragCharSize, int maxNumFragments) return the best fragments.final String[]
FastVectorHighlighter.getBestFragments
(FieldQuery fieldQuery, IndexReader reader, int docId, String fieldName, int fragCharSize, int maxNumFragments, FragListBuilder fragListBuilder, FragmentsBuilder fragmentsBuilder, String[] preTags, String[] postTags, Encoder encoder) return the best fragments.final String[]
FastVectorHighlighter.getBestFragments
(FieldQuery fieldQuery, IndexReader reader, int docId, String storedField, Set<String> matchedFields, int fragCharSize, int maxNumFragments, FragListBuilder fragListBuilder, FragmentsBuilder fragmentsBuilder, String[] preTags, String[] postTags, Encoder encoder) Return the best fragments.private FieldFragList
FastVectorHighlighter.getFieldFragList
(FragListBuilder fragListBuilder, FieldQuery fieldQuery, IndexReader reader, int docId, String matchedField, int fragCharSize) Build a FieldFragList for one field.private FieldFragList
FastVectorHighlighter.getFieldFragList
(FragListBuilder fragListBuilder, FieldQuery fieldQuery, IndexReader reader, int docId, Set<String> matchedFields, int fragCharSize) Build a FieldFragList for more than one field.FastVectorHighlighter.getFieldQuery
(Query query, IndexReader reader) create aFieldQuery
object.protected Field[]
BaseFragmentsBuilder.getFields
(IndexReader reader, int docId, String fieldName) Constructors in org.apache.lucene.search.vectorhighlight with parameters of type IndexReaderModifierConstructorDescriptionFieldQuery
(Query query, IndexReader reader, boolean phraseHighlight, boolean fieldMatch) FieldTermStack
(IndexReader reader, int docId, String fieldName, FieldQuery fieldQuery) a constructor.
Query.rewrite(IndexSearcher)