Class BucketCollector

java.lang.Object
org.elasticsearch.search.aggregations.BucketCollector
Direct Known Subclasses:
Aggregator, DeferringBucketCollector, MultiBucketCollector

public abstract class BucketCollector extends Object
A Collector that can collect data in separate buckets.
  • Field Details

    • NO_OP_BUCKET_COLLECTOR

      public static final BucketCollector NO_OP_BUCKET_COLLECTOR
    • NO_OP_COLLECTOR

      public static final org.apache.lucene.search.Collector NO_OP_COLLECTOR
  • Constructor Details

    • BucketCollector

      public BucketCollector()
  • Method Details

    • getLeafCollector

      public abstract LeafBucketCollector getLeafCollector(AggregationExecutionContext aggCtx) throws IOException
      Throws:
      IOException
    • preCollection

      public abstract void preCollection() throws IOException
      Pre collection callback.
      Throws:
      IOException
    • postCollection

      public abstract void postCollection() throws IOException
      Post-collection callback.
      Throws:
      IOException
    • scoreMode

      public abstract org.apache.lucene.search.ScoreMode scoreMode()
      Indicates what features are required from the scorer.
    • asCollector

      public final org.apache.lucene.search.Collector asCollector()
      Return this BucketCollector wrapped as a Collector