org.elasticsearch.search.facet.histogram.unbounded
Class CountHistogramFacetCollector
java.lang.Object
org.apache.lucene.search.Collector
org.elasticsearch.search.facet.FacetCollector
org.elasticsearch.search.facet.AbstractFacetCollector
org.elasticsearch.search.facet.histogram.unbounded.CountHistogramFacetCollector
public class CountHistogramFacetCollector
- extends AbstractFacetCollector
A histogram facet collector that uses the same field as the key as well as the
value.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CountHistogramFacetCollector
public CountHistogramFacetCollector(String facetName,
String fieldName,
long interval,
HistogramFacet.ComparatorType comparatorType,
SearchContext context)
doCollect
protected void doCollect(int doc)
throws IOException
- Specified by:
doCollect
in class AbstractFacetCollector
- Throws:
IOException
doSetNextReader
protected void doSetNextReader(org.apache.lucene.index.IndexReader reader,
int docBase)
throws IOException
- Specified by:
doSetNextReader
in class AbstractFacetCollector
- Throws:
IOException
facet
public Facet facet()
- Specified by:
facet
in class FacetCollector
bucket
public static long bucket(double value,
long interval)
Copyright © 2009-2012. All Rights Reserved.