java.lang.Object
org.apache.lucene.search.SimpleCollector
org.hibernate.search.backend.lucene.lowlevel.collector.impl.TimeoutCountCollector
All Implemented Interfaces:
org.apache.lucene.search.Collector, org.apache.lucene.search.LeafCollector

public class TimeoutCountCollector extends org.apache.lucene.search.SimpleCollector
Counts the total hit, as TotalHitCountCollector does. Moreover, it periodically checks for timeout.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    collect(int doc)
     
    int
    Returns how many hits matched the search.
    org.apache.lucene.search.ScoreMode
     

    Methods inherited from class org.apache.lucene.search.SimpleCollector

    doSetNextReader, getLeafCollector, setScorer

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.lucene.search.Collector

    setWeight

    Methods inherited from interface org.apache.lucene.search.LeafCollector

    collect, competitiveIterator, finish
  • Constructor Details

    • TimeoutCountCollector

      public TimeoutCountCollector(Deadline deadline)
  • Method Details

    • getTotalHits

      public int getTotalHits()
      Returns how many hits matched the search.
    • collect

      public void collect(int doc)
      Specified by:
      collect in interface org.apache.lucene.search.LeafCollector
      Specified by:
      collect in class org.apache.lucene.search.SimpleCollector
    • scoreMode

      public org.apache.lucene.search.ScoreMode scoreMode()