|
| TopScoreDocCollector (int32_t numHits) |
|
virtual | ~TopScoreDocCollector () |
|
virtual String | getClassName () |
|
boost::shared_ptr< TopScoreDocCollector > | shared_from_this () |
|
virtual void | setNextReader (const IndexReaderPtr &reader, int32_t docBase) |
| Called before collecting from each IndexReader. All doc ids in collect(int32_t) will correspond to reader. Add docBase to the current IndexReaders internal document id to re-base ids in collect(int32_t) . More...
|
|
virtual void | setScorer (const ScorerPtr &scorer) |
| Called before successive calls to collect(int32_t) . Implementations that need the score of the current document (passed-in to collect(int32_t) ), should save the passed-in Scorer and call scorer.score() when needed. More...
|
|
| TopDocsCollector (const HitQueueBasePtr &pq) |
|
virtual | ~TopDocsCollector () |
|
virtual String | getClassName () |
|
boost::shared_ptr< TopDocsCollector > | shared_from_this () |
|
virtual int32_t | getTotalHits () |
| The total number of documents that matched this query. More...
|
|
virtual TopDocsPtr | topDocs () |
| Returns the top docs that were collected by this collector. More...
|
|
virtual TopDocsPtr | topDocs (int32_t start) |
| Returns the documents in the range [start .. pq.size()) that were collected by this collector. Note that if start >= pq.size(), an empty TopDocs is returned. More...
|
|
virtual TopDocsPtr | topDocs (int32_t start, int32_t howMany) |
| Returns the documents in the rage [start .. start + howMany) that were collected by this collector. Note that if start >= pq.size(), an empty TopDocs is returned, and if pq.size() - start < howMany, then only the available documents in [start .. pq.size()) are returned. More...
|
|
virtual | ~Collector () |
|
virtual String | getClassName () |
|
boost::shared_ptr< Collector > | shared_from_this () |
|
virtual void | setScorer (const ScorerPtr &scorer)=0 |
| Called before successive calls to collect(int32_t) . Implementations that need the score of the current document (passed-in to collect(int32_t) ), should save the passed-in Scorer and call scorer.score() when needed. More...
|
|
virtual void | collect (int32_t doc)=0 |
| Called once for every document matching a query, with the unbased document number. More...
|
|
virtual void | setNextReader (const IndexReaderPtr &reader, int32_t docBase)=0 |
| Called before collecting from each IndexReader. All doc ids in collect(int32_t) will correspond to reader. Add docBase to the current IndexReaders internal document id to re-base ids in collect(int32_t) . More...
|
|
virtual bool | acceptsDocsOutOfOrder ()=0 |
| Return true if this collector does not require the matching docIDs to be delivered in int sort order (smallest to largest) to collect . More...
|
|
virtual | ~LuceneObject () |
|
virtual void | initialize () |
| Called directly after instantiation to create objects that depend on this object being fully constructed. More...
|
|
virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr()) |
| Return clone of this object. More...
|
|
virtual int32_t | hashCode () |
| Return hash code for this object. More...
|
|
virtual bool | equals (const LuceneObjectPtr &other) |
| Return whether two objects are equal. More...
|
|
virtual int32_t | compareTo (const LuceneObjectPtr &other) |
| Compare two objects. More...
|
|
virtual String | toString () |
| Returns a string representation of the object. More...
|
|
virtual | ~LuceneSync () |
|
virtual SynchronizePtr | getSync () |
| Return this object synchronize lock. More...
|
|
virtual LuceneSignalPtr | getSignal () |
| Return this object signal. More...
|
|
virtual void | lock (int32_t timeout=0) |
| Lock this object using an optional timeout. More...
|
|
virtual void | unlock () |
| Unlock this object. More...
|
|
virtual bool | holdsLock () |
| Returns true if this object is currently locked by current thread. More...
|
|
virtual void | wait (int32_t timeout=0) |
| Wait for signal using an optional timeout. More...
|
|
virtual void | notifyAll () |
| Notify all threads waiting for signal. More...
|
|
A Collector
implementation that collects the top-scoring hits, returning them as a TopDocs
. This is used by IndexSearcher
to implement 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 Nan, NEGATIVE_INFINITY and POSITIVE_INFINITY are not valid scores. This collector will not properly collect hits with such scores.