MapBasics<K, V> extension
Utility extension methods for the native Map class.
- on
-
- Map<
K, V>
- Map<
Methods
-
get(
K key, {V? defaultValue}) → V? -
Available on Map<
A type-checked version of operator [] that additionally supports returning a default value.K, V> , provided by the MapBasics extension -
invert(
) → Map< V, K> -
Available on Map<
Returns a new Map where each entry is inverted, with the key becoming the value and the value becoming the key.K, V> , provided by the MapBasics extension -
whereKey(
bool test(K)) → Map< K, V> -
Available on Map<
Returns a new Map containing all the entries ofK, V> , provided by the MapBasics extensionthis
for which the key satisfiestest
. -
whereValue(
bool test(V)) → Map< K, V> -
Available on Map<
Returns a new Map containing all the entries ofK, V> , provided by the MapBasics extensionthis
for which the value satisfiestest
.