@Override protected void doSetNextReader(LeafReaderContext context) throws IOException { FunctionValues values = groupSource.getValues(vsContext, context); groupFiller = values.getValueFiller(); groupMval = groupFiller.getValue(); values = countSource.getValues(vsContext, context); countFiller = values.getValueFiller(); countMval = countFiller.getValue(); }
@Override public void collect(int doc) throws IOException { groupFiller.fillValue(doc); GroupCount groupCount = groupMap.get(groupMval); if (groupCount != null) { countFiller.fillValue(doc); groupCount.uniqueValues.add(countMval.duplicate()); } }