mapValues<U> method
New map with same keys, values transformed by f.
Audited: 2026-06-12 11:26 EDT
Implementation
@useResult
Map<K, U> mapValues<U>(U Function(V value) f) =>
Map<K, U>.fromEntries(entries.map((MapEntry<K, V> e) => MapEntry<K, U>(e.key, f(e.value))));