org.apache.cassandra.db.aggregation

## Class AggregationSpecification

- java.lang.Object
- - org.apache.cassandra.db.aggregation.AggregationSpecification

    public abstract class AggregationSpecification
    extends java.lang.Object

Defines how rows should be grouped for creating aggregates.

### Nested Class Summary

Nested Classes
`static class` `AggregationSpecification.Kind` The `AggregationSpecification` kinds.
`static class` `AggregationSpecification.Serializer`

### Field Summary

Fields
`static AggregationSpecification` `AGGREGATE_EVERYTHING` `AggregationSpecification` that group all the row together.
`static AggregationSpecification.Serializer` `serializer`

### Method Summary

All Methods Static Methods Instance Methods Abstract Methods Concrete Methods
`static AggregationSpecification` `aggregatePkPrefix(ClusteringComparator comparator, int clusteringPrefixSize)` Creates a new `AggregationSpecification` instance that will build aggregates based on primary key columns.
`AggregationSpecification.Kind` `kind()` Returns the `AggregationSpecification` kind.
`GroupMaker` `newGroupMaker()` Creates a new `GroupMaker` instance.
`abstract GroupMaker` `newGroupMaker(GroupingState state)` Creates a new `GroupMaker` instance.

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

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

### Field Detail

#### serializer

    public static final AggregationSpecification.Serializer serializer

#### AGGREGATE_EVERYTHING

    public static final AggregationSpecification AGGREGATE_EVERYTHING

`AggregationSpecification` that group all the row together.

### Method Detail

#### kind

    public AggregationSpecification.Kind kind()

Returns the `AggregationSpecification` kind.

Returns:
  the `AggregationSpecification` kind

#### newGroupMaker

    public final GroupMaker newGroupMaker()

Creates a new `GroupMaker` instance.

Returns:
  a new `GroupMaker` instance

#### newGroupMaker

    public abstract GroupMaker newGroupMaker(GroupingState state)

Creates a new `GroupMaker` instance.

Parameters:
  `state` - `GroupMaker` state
Returns:
  a new `GroupMaker` instance

#### aggregatePkPrefix

    public static AggregationSpecification aggregatePkPrefix(ClusteringComparator comparator,
                                                             int clusteringPrefixSize)

Creates a new `AggregationSpecification` instance that will build aggregates based on primary key columns.

Parameters:
  `comparator` - the comparator used to compare the clustering prefixes
  `clusteringPrefixSize` - the number of clustering columns used to create the aggregates
Returns:
  a new `AggregationSpecification` instance that will build aggregates based on primary key columns