private void processAggregators(List<AggregatorInstance<?>> aggregatorInstances) { for (AggregatorInstance aggregatorInstance : aggregatorInstances) { if (aggregatorInstance instanceof Count) { count(); } else if (aggregatorInstance instanceof Average) { average(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Sum) { sum(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Min) { min(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Max) { max(aggregatorInstance.getAttribute().getAttributeName()); } else { throw new SearchException("unknown aggregator type: " + aggregatorInstance.getClass().getName()); } } }
private void processAggregators(List<AggregatorInstance<?>> aggregatorInstances) { for (AggregatorInstance aggregatorInstance : aggregatorInstances) { if (aggregatorInstance instanceof Count) { count(); } else if (aggregatorInstance instanceof Average) { average(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Sum) { sum(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Min) { min(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Max) { max(aggregatorInstance.getAttribute().getAttributeName()); } else { throw new SearchException("unknown aggregator type: " + aggregatorInstance.getClass().getName()); } } }
private void processAggregators(List<AggregatorInstance<?>> aggregatorInstances) { for (AggregatorInstance aggregatorInstance : aggregatorInstances) { if (aggregatorInstance instanceof Count) { count(); } else if (aggregatorInstance instanceof Average) { average(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Sum) { sum(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Min) { min(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Max) { max(aggregatorInstance.getAttribute().getAttributeName()); } else { throw new SearchException("unknown aggregator type: " + aggregatorInstance.getClass().getName()); } } }
private void processAggregators(List<AggregatorInstance<?>> aggregatorInstances) { for (AggregatorInstance aggregatorInstance : aggregatorInstances) { if (aggregatorInstance instanceof Count) { count(); } else if (aggregatorInstance instanceof Average) { average(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Sum) { sum(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Min) { min(aggregatorInstance.getAttribute().getAttributeName()); } else if (aggregatorInstance instanceof Max) { max(aggregatorInstance.getAttribute().getAttributeName()); } else { throw new SearchException("unknown aggregator type: " + aggregatorInstance.getClass().getName()); } } }