org.elasticsearch.search.facet.query
Class QueryFacetCollector

java.lang.Object
  extended by org.apache.lucene.search.Collector
      extended by org.elasticsearch.search.facet.FacetCollector
          extended by org.elasticsearch.search.facet.AbstractFacetCollector
              extended by org.elasticsearch.search.facet.query.QueryFacetCollector
All Implemented Interfaces:
OptimizeGlobalFacetCollector

public class QueryFacetCollector
extends AbstractFacetCollector
implements OptimizeGlobalFacetCollector


Field Summary
 
Fields inherited from class org.elasticsearch.search.facet.AbstractFacetCollector
facetName
 
Constructor Summary
QueryFacetCollector(java.lang.String facetName, org.apache.lucene.search.Query query, FilterCache filterCache)
           
 
Method Summary
protected  void doCollect(int doc)
           
protected  void doSetNextReader(org.apache.lucene.index.IndexReader reader, int docBase)
           
 Facet facet()
           
 void optimizedGlobalExecution(SearchContext searchContext)
           
 
Methods inherited from class org.elasticsearch.search.facet.AbstractFacetCollector
acceptsDocsOutOfOrder, collect, getFilter, setFilter, setNextReader, setScorer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QueryFacetCollector

public QueryFacetCollector(java.lang.String facetName,
                           org.apache.lucene.search.Query query,
                           FilterCache filterCache)
Method Detail

doSetNextReader

protected void doSetNextReader(org.apache.lucene.index.IndexReader reader,
                               int docBase)
                        throws java.io.IOException
Specified by:
doSetNextReader in class AbstractFacetCollector
Throws:
java.io.IOException

doCollect

protected void doCollect(int doc)
                  throws java.io.IOException
Specified by:
doCollect in class AbstractFacetCollector
Throws:
java.io.IOException

optimizedGlobalExecution

public void optimizedGlobalExecution(SearchContext searchContext)
                              throws java.io.IOException
Specified by:
optimizedGlobalExecution in interface OptimizeGlobalFacetCollector
Throws:
java.io.IOException

facet

public Facet facet()
Specified by:
facet in class FacetCollector