presto-main/src/main/java/io/prestosql/operator/aggregation/MapAggregationFunction.java/MapAggregationFunction/output
class MapAggregationFunction:    public static void output(KeyValuePairsState state, BlockBuilder out)
    {
        KeyValuePairs pairs = state.get();
        if (pairs == null) {
            out.appendNull();
        }
        else {
            pairs.serialize(out);
        }
    }