Class ValuesSourceRegistry.Builder

java.lang.Object
org.elasticsearch.search.aggregations.support.ValuesSourceRegistry.Builder
Enclosing class:
ValuesSourceRegistry

public static class ValuesSourceRegistry.Builder
extends java.lang.Object
  • Constructor Summary

    Constructors 
    Constructor Description
    Builder()  
  • Method Summary

    Modifier and Type Method Description
    ValuesSourceRegistry build()  
    void register​(java.lang.String aggregationName, java.util.List<ValuesSourceType> valuesSourceTypes, AggregatorSupplier aggregatorSupplier)
    Register a ValuesSource to Aggregator mapping.
    void register​(java.lang.String aggregationName, ValuesSourceType valuesSourceType, AggregatorSupplier aggregatorSupplier)
    Register a ValuesSource to Aggregator mapping.
    void registerUsage​(java.lang.String aggregationName)  
    void registerUsage​(java.lang.String aggregationName, ValuesSourceType valuesSourceType)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • register

      public void register​(java.lang.String aggregationName, ValuesSourceType valuesSourceType, AggregatorSupplier aggregatorSupplier)
      Register a ValuesSource to Aggregator mapping. This method registers mappings that only apply to a single ValuesSourceType
      Parameters:
      aggregationName - The name of the family of aggregations, typically found via BaseAggregationBuilder.getType()
      valuesSourceType - The ValuesSourceType this mapping applies to.
      aggregatorSupplier - An Aggregation-specific specialization of AggregatorSupplier which will construct the mapped aggregator from the aggregation standard set of parameters
    • register

      public void register​(java.lang.String aggregationName, java.util.List<ValuesSourceType> valuesSourceTypes, AggregatorSupplier aggregatorSupplier)
      Register a ValuesSource to Aggregator mapping. This version provides a convenience method for mappings that apply to a known list of ValuesSourceType
      Parameters:
      aggregationName - The name of the family of aggregations, typically found via BaseAggregationBuilder.getType()
      valuesSourceTypes - The ValuesSourceTypes this mapping applies to.
      aggregatorSupplier - An Aggregation-specific specialization of AggregatorSupplier which will construct the mapped aggregator from the aggregation standard set of parameters
    • registerUsage

      public void registerUsage​(java.lang.String aggregationName, ValuesSourceType valuesSourceType)
    • registerUsage

      public void registerUsage​(java.lang.String aggregationName)
    • build

      public ValuesSourceRegistry build()