public final class MapUtil
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static <E,K,V> java.util.stream.Collector<E,java.util.Map<K,V>,java.util.Map<K,V>> |
collector(java.util.function.Function<? super E,? extends K> keyMapper,
java.util.function.Function<? super E,? extends V> valueMapper)
Custom collector for maps.
|
public static <E,K,V> java.util.stream.Collector<E,java.util.Map<K,V>,java.util.Map<K,V>> collector(java.util.function.Function<? super E,? extends K> keyMapper, java.util.function.Function<? super E,? extends V> valueMapper)
Custom collector for maps.
This collector behaves like Collectors.toMap(Function, Function)
except that it allows null
values.
keyMapper
- map function for the key set.valueMapper
- map function for the value set.Copyright © 2003-2019 The KeY-Project.