Package org.apache.lucene.facet.taxonomy

## Class AssociationAggregationFunction

- java.lang.Object
- - org.apache.lucene.facet.taxonomy.AssociationAggregationFunction

-     public abstract class AssociationAggregationFunction
      extends Object

  Specify aggregation logic used in `TaxonomyFacetIntAssociations` and `TaxonomyFacetFloatAssociations`.

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `static AssociationAggregationFunction` | `MAX` | Aggregation that computes the maximum value
    `static AssociationAggregationFunction` | `SUM` | Aggregation that computes the sum

  - ### Constructor Summary

    Constructors
    Modifier | Constructor | Description
    --- | --- | ---
    `protected` | `AssociationAggregationFunction()` | Sole constructor.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `abstract float` | `aggregate​(float existingVal, float newVal)` | Implement aggregation logic for floats
    `abstract int` | `aggregate​(int existingVal, int newVal)` | Implement aggregation logic for integers

    - ### Methods inherited from class java.lang.Object

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

- - ### Field Detail

    - #### MAX

          public static final AssociationAggregationFunction MAX

      Aggregation that computes the maximum value

    - #### SUM

          public static final AssociationAggregationFunction SUM

      Aggregation that computes the sum

  - ### Constructor Detail

    - #### AssociationAggregationFunction

          protected AssociationAggregationFunction()

      Sole constructor.

  - ### Method Detail

    - #### aggregate

          public abstract int aggregate​(int existingVal,
                                        int newVal)

      Implement aggregation logic for integers

    - #### aggregate

          public abstract float aggregate​(float existingVal,
                                          float newVal)

      Implement aggregation logic for floats