for (Facet facet : facets) {
InternalLongTermsFacet mFacet = (InternalLongTermsFacet) facet;
missing += mFacet.missingCount();
total += mFacet.totalCount();
for (LongEntry entry : mFacet.entries) {
aggregated.adjustOrPutValue(entry.term, entry.count(), entry.count());
}
}
BoundedTreeSet<LongEntry> ordered = new BoundedTreeSet<LongEntry>(first.comparatorType.comparator(), first.requiredSize);
for (TLongIntIterator it = aggregated.iterator(); it.hasNext(); ) {