Say I have a Map extends Object, List>
Map extends Object, List>
I can get the values of the map easily enough, and iterate over it to produce a single
Flatten on a function:
private List flatten(List list, Function> flattenFn) { return list .stream() .map(flattenFn) .flatMap(Collection::stream) .collect(Collectors.toUnmodifiableList()); }