Uses of Class
org.apache.lucene.search.TopDocs
-
Packages that use TopDocs Package Description org.apache.lucene.index Code to maintain and access indices.org.apache.lucene.search Code to search indices.org.apache.lucene.search.knn Classes related to vector search: knn and vector fields.org.apache.lucene.util.hnsw Navigable Small-World graph, nominally Hierarchical but currently only has a single layer. -
-
Uses of TopDocs in org.apache.lucene.index
Methods in org.apache.lucene.index that return TopDocs Modifier and Type Method Description TopDocsLeafReader. searchNearestVectors(String field, byte[] target, int k, Bits acceptDocs, int visitedLimit)Return the k nearest neighbor documents as determined by comparison of their vector values for this field, to the given vector, by the field's similarity function.TopDocsLeafReader. searchNearestVectors(String field, float[] target, int k, Bits acceptDocs, int visitedLimit)Return the k nearest neighbor documents as determined by comparison of their vector values for this field, to the given vector, by the field's similarity function. -
Uses of TopDocs in org.apache.lucene.search
Subclasses of TopDocs in org.apache.lucene.search Modifier and Type Class Description classTopFieldDocsRepresents hits returned byIndexSearcher.search(Query,int,Sort).Fields in org.apache.lucene.search declared as TopDocs Modifier and Type Field Description static TopDocsTopDocsCollector. EMPTY_TOPDOCSThis is used in case topDocs() is called with illegal parameters, or there simply aren't (enough) results.Methods in org.apache.lucene.search that return TopDocs Modifier and Type Method Description protected TopDocsByteVectorSimilarityQuery. approximateSearch(LeafReaderContext context, Bits acceptDocs, int visitLimit)protected TopDocsFloatVectorSimilarityQuery. approximateSearch(LeafReaderContext context, Bits acceptDocs, int visitLimit)protected TopDocsKnnByteVectorQuery. approximateSearch(LeafReaderContext context, Bits acceptDocs, int visitedLimit, KnnCollectorManager knnCollectorManager)protected TopDocsKnnFloatVectorQuery. approximateSearch(LeafReaderContext context, Bits acceptDocs, int visitedLimit, KnnCollectorManager knnCollectorManager)static TopDocsTopDocs. merge(int start, int topN, TopDocs[] shardHits)Same asmerge(int, TopDocs[])but also ignores the topstarttop docs.static TopDocsTopDocs. merge(int start, int topN, TopDocs[] shardHits, Comparator<ScoreDoc> tieBreaker)Same as above, but accepts the passed in tie breakerstatic TopDocsTopDocs. merge(int topN, TopDocs[] shardHits)Returns a new TopDocs, containing topN results across the provided TopDocs, sorting by score.protected TopDocsTopDocsCollector. newTopDocs(ScoreDoc[] results, int start)Returns aTopDocsinstance containing the given results.protected TopDocsTopFieldCollector. newTopDocs(ScoreDoc[] results, int start)protected TopDocsTopScoreDocCollector. newTopDocs(ScoreDoc[] results, int start)TopDocsTopScoreDocCollectorManager. reduce(Collection<TopScoreDocCollector> collectors)TopDocsQueryRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN)static TopDocsQueryRescorer. rescore(IndexSearcher searcher, TopDocs topDocs, Query query, double weight, int topN)Sugar API, calling {#rescore} using a simple linear combination of firstPassScore + weight * secondPassScoreabstract TopDocsRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN)Rescore an initial first-passTopDocs.TopDocsSortRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN)TopDocsIndexSearcher. search(Query query, int n)Finds the topnhits forquery.TopDocsIndexSearcher. searchAfter(ScoreDoc after, Query query, int numHits)Finds the topnhits forquerywhere all results are after a previous result (after).TopDocsIndexSearcher. searchAfter(ScoreDoc after, Query query, int n, Sort sort)Finds the topnhits forquerywhere all results are after a previous result (after).abstract TopDocsAbstractKnnCollector. topDocs()TopDocsKnnCollector. topDocs()This drains the collected nearest kNN results and returns them in a newTopDocscollection, ordered by score descending.TopDocsTopDocsCollector. topDocs()Returns the top docs that were collected by this collector.TopDocsTopDocsCollector. topDocs(int start)Returns the documents in the range [start ..TopDocsTopDocsCollector. topDocs(int start, int howMany)Returns the documents in the range [start ..TopDocsTopKnnCollector. topDocs()Methods in org.apache.lucene.search that return types with arguments of type TopDocs Modifier and Type Method Description static CollectorManager<TopScoreDocCollector,TopDocs>TopScoreDocCollector. createSharedManager(int numHits, ScoreDoc after, int totalHitsThreshold)Deprecated.This method is deprecated in favor of the constructor ofTopScoreDocCollectorManagerdue to its support for concurrency in IndexSearcherMethods in org.apache.lucene.search with parameters of type TopDocs Modifier and Type Method Description static TopDocsTopDocs. merge(int start, int topN, TopDocs[] shardHits)Same asmerge(int, TopDocs[])but also ignores the topstarttop docs.static TopDocsTopDocs. merge(int start, int topN, TopDocs[] shardHits, Comparator<ScoreDoc> tieBreaker)Same as above, but accepts the passed in tie breakerstatic TopDocsTopDocs. merge(int topN, TopDocs[] shardHits)Returns a new TopDocs, containing topN results across the provided TopDocs, sorting by score.TopDocsQueryRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN)static TopDocsQueryRescorer. rescore(IndexSearcher searcher, TopDocs topDocs, Query query, double weight, int topN)Sugar API, calling {#rescore} using a simple linear combination of firstPassScore + weight * secondPassScoreabstract TopDocsRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN)Rescore an initial first-passTopDocs.TopDocsSortRescorer. rescore(IndexSearcher searcher, TopDocs firstPassTopDocs, int topN) -
Uses of TopDocs in org.apache.lucene.search.knn
Methods in org.apache.lucene.search.knn that return TopDocs Modifier and Type Method Description TopDocsMultiLeafKnnCollector. topDocs() -
Uses of TopDocs in org.apache.lucene.util.hnsw
Methods in org.apache.lucene.util.hnsw that return TopDocs Modifier and Type Method Description TopDocsHnswGraphBuilder.GraphBuilderKnnCollector. topDocs()TopDocsOrdinalTranslatedKnnCollector. topDocs()
-