Uses of Package
org.apache.lucene.search
Package
Description
Codecs API: API for customization of the encoding and structure of the index.
Lucene 9.1 file format.
Postings format that can delegate to different formats per-field.
The logical representation of a
Document
for indexing and
searching.Code to maintain and access indices.
Code to search indices.
Comparators, used to compare hits so as to determine their sort order when collecting the top
results with
TopFieldCollector
.This package contains the various ranking models that can be used in Lucene.
Some utility classes.
Finite-state automaton for regular expressions.
-
-
-
-
ClassDescriptionBase class for producing
DoubleValues
Implements search over a single IndexReader.The abstract base class for queries.Allows recursion through a query treeDifferent modes of search.Stores information about how to sort documents by terms in an individual field.Expert: Calculate query weights and build query scorers. -
ClassDescriptionA DocIdSet contains a set of doc ids.This abstract class defines methods to iterate over a set of non-decreasing doc ids.The abstract base class for queries.Utility class to safely share instances of a certain type across multiple threads, while periodically refreshing them.Encapsulates sort criteria for returned hits.Stores information about how to sort documents by terms in an individual field.Represents hits returned by
IndexSearcher.search(Query,int)
. -
ClassDescriptionA
Query
that will match terms against a finite-state machine.AQuery
that blends index statistics across multiple terms.A Builder forBlendedTermQuery
.ABlendedTermQuery.RewriteMethod
defines how queries for individual terms should be merged.A clause in a BooleanQuery.Specifies how clauses are to occur in matching documents.A Query that matches documents matching boolean combinations of other queries, e.g.A builder for boolean queries.Add thisAttribute
to aTermsEnum
returned byMultiTermQuery.getTermsEnum(Terms,AttributeSource)
and update the boost on each returned term.This class is used to score a range of documents at once, and is returned byWeight.bulkScorer(org.apache.lucene.index.LeafReaderContext)
.Caches all docs, and optionally also scores, coming from a search, and is then able to replay them to another collector.Contains statistics for a collection (field).Expert: Collectors are primarily meant to be used to gather raw results from a search, and implement sorting or custom result filtering, collation, etc.A manager of collectors.A priority queue of DocIdSetIterators that orders by current doc ID.Wrapper used inDisiPriorityQueue
.A DocIdSet contains a set of doc ids.This abstract class defines methods to iterate over a set of non-decreasing doc ids.Per-segment, per-document double values, which can be calculated at search-timeBase class for producingDoubleValues
Expert: Describes the score computation for document and query.Expert: a FieldComparator compares hits so as to determine their sort order when collecting the top results withTopFieldCollector
.Provides aFieldComparator
for custom field sorting.Expert: A ScoreDoc which also contains information about how to sort the referenced document.Expert: A hit queue for sorting by hits by terms in more than one field.Extension of ScoreDoc to also store theFieldComparator
slot.Collector
delegator.Implements search over a single IndexReader.A class holding a subset of theIndexSearcher
s leaf contexts to be executed within a single thread.Thrown when an attempt is made to add more thanIndexSearcher.TooManyClauses.getMaxClauseCount()
clauses.A Query that matches documents matching combinations of subqueries.The Indri implemenation of a disjunction scorer which stores the subscorers for the child queries.A Basic abstract query that all IndriQueries can extend to implement toString, equals, getClauses, and iterator.The Indri parent scorer that stores the boost so that IndriScorers can use the boost outside of the term.Collector decouples the score from the collected doc: the score computation is skipped entirely if it's not needed.Expert: comparator that gets instantiated on each leaf from a top-levelFieldComparator
instance.Similarity.SimScorer
on a specificLeafReader
.Per-segment, per-document long values, which can be calculated at search-timeBase class for producingLongValues
Cache of doc ids with a count.Reports the positions and optionally offsets of all matching terms in a query for a single documentAn iterator over match positions (and optionally offsets) for a single document and fieldAdd thisAttribute
to a freshAttributeSource
before callingMultiTermQuery.getTermsEnum(Terms,AttributeSource)
.A generalized version ofPhraseQuery
, with the possibility of adding more than one term at the same position that are treated as a disjunction (OR).A builder for multi-phrase queriesTakes the logical union of multiple PostingsEnum iterators.An abstractQuery
that matches documents containing a subset of terms provided by aFilteredTermsEnum
enumeration.Abstract class that defines how the query is rewritten.Utility class to help extract the set of sub queries that have matched from a larger query.Base class for exact and sloppy phrase matchingA Query that matches documents containing a particular sequence of terms.A builder for phrase queries.Term postings and position information for phrase matchingIterator of encoded point values.The abstract base class for queries.A cache for queries.A policy defining which filters should be cached.Allows recursion through a query treeUtility class to safely share instances of a certain type across multiple threads, while periodically refreshing them.Use to receive notification when a refresh has finished.Re-scores the topN results (TopDocs
) from an original query.Allows access to the score of a QueryA child Scorer and its relationship to its parent.Holds one hit inTopDocs
.Different modes of search.Expert: Common scoring functionality for different types of queries.A supplier ofScorer
.Base rewrite method that translates each term into a query, and keeps the scores as computed by the query.Factory class used bySearcherManager
to create new IndexSearchers.Interface defining whether or not an object can be cached against aLeafReader
BaseCollector
implementation that is used to collect all contexts.Encapsulates sort criteria for returned hits.Type of selection to perform.Type of selection to perform.Stores information about how to sort documents by terms in an individual field.Specifies the type of the terms to be sorted, or special types such as CUSTOMA query that treats multiple terms as synonyms.A builder forSynonymQuery
.A Query that matches documents within an range of terms.Contains statistics for a specific termThread used to timeout search requests.Represents hits returned byIndexSearcher.search(Query,int)
.A base class for all collectors that return aTopDocs
output.Represents hits returned byIndexSearcher.search(Query,int,Sort)
.Base rewrite method for collecting only the top terms via a priority queue.Just counts the total number of hits.Description of the total number of hits of a query.How theTotalHits.value
should be interpreted.Returned byScorer.twoPhaseIterator()
to expose an approximation of aDocIdSetIterator
.Expert: Calculate query weights and build query scorers. -
ClassDescriptionThis abstract class defines methods to iterate over a set of non-decreasing doc ids.Expert: a FieldComparator compares hits so as to determine their sort order when collecting the top results with
TopFieldCollector
.Expert: comparator that gets instantiated on each leaf from a top-levelFieldComparator
instance.Allows access to the score of a Query -
ClassDescriptionContains statistics for a collection (field).Expert: Describes the score computation for document and query.Contains statistics for a specific term
-
ClassDescriptionSpecifies how clauses are to occur in matching documents.A builder for boolean queries.A DocIdSet contains a set of doc ids.This abstract class defines methods to iterate over a set of non-decreasing doc ids.A builder for multi-phrase queriesThe abstract base class for queries.
-
ClassDescriptionThe abstract base class for queries.Allows recursion through a query tree