A {@link Collector} implementation that collects the top-scoring hits, returning them as a {@link TopDocs}. This is used by {@link IndexSearcher} to implement {@link TopDocs}-based search. Hits are sorted by score descending and then (when the scores are tied) docID ascending. When you create an instance of this collector you should know in advance whether documents are going to be collected in doc Id order or not.

NOTE: The values {@link Float#NaN} and {Float#NEGATIVE_INFINITY} are not valid scores. This collector will not properly collect hits with such scores.

Namespace: Lucene.Net.Search
Assembly: Lucene.Net (in Lucene.Net.dll) Version: 2.9.4.1

Syntax

C#
public abstract class TopScoreDocCollector : TopDocsCollector
Visual Basic
Public MustInherit Class TopScoreDocCollector _
	Inherits TopDocsCollector
Visual C++
public ref class TopScoreDocCollector abstract : public TopDocsCollector

Inheritance Hierarchy

System..::..Object
  Lucene.Net.Search..::..Collector
    Lucene.Net.Search..::..TopDocsCollector
      Lucene.Net.Search..::..TopScoreDocCollector

See Also