@Override public TemplateDruidQuery withAggregations(Collection<Aggregation> newAggregations){
  return new TemplateDruidQuery(newAggregations,postAggregations,nestedQuery,timeGrain);
}

@ Override public TemplateDruidQuery withAggregations ( Collection < Aggregation > newAggregations ) { return new TemplateDruidQuery ( newAggregations , postAggregations , nestedQuery , timeGrain ) ; }
makes a copy of the template query and any sub query ( s ) , changing aggregations . < p > everything is a shallow copy .
