mirror of
https://github.com/spring-projects/spring-data-elasticsearch.git
synced 2025-06-15 16:42:11 +00:00
parent
c93039410a
commit
c4910bf399
@ -41,11 +41,10 @@ public class ElasticsearchAggregations implements AggregationsContainer<List<Ela
|
|||||||
|
|
||||||
Assert.notNull(aggregations, "aggregations must not be null");
|
Assert.notNull(aggregations, "aggregations must not be null");
|
||||||
|
|
||||||
Map<String, ElasticsearchAggregation> elasticsearchAggregationsAsMap = new HashMap<>(aggregations.size());
|
aggregationsAsMap = new HashMap<>();
|
||||||
aggregations.forEach((name, aggregate) -> elasticsearchAggregationsAsMap //
|
aggregations.forEach((name, aggregate) -> aggregationsAsMap //
|
||||||
.put(name, new ElasticsearchAggregation(new Aggregation(name, aggregate))));
|
.put(name, new ElasticsearchAggregation(new Aggregation(name, aggregate))));
|
||||||
|
|
||||||
this.aggregationsAsMap = elasticsearchAggregationsAsMap;
|
|
||||||
this.aggregations = new ArrayList<>(aggregationsAsMap.values());
|
this.aggregations = new ArrayList<>(aggregationsAsMap.values());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user