where method

Map<K, V> where(
  1. bool predicate(
    1. K key,
    2. V value
    )
)

Returns a new map with all entries that satisfy the predicate test.

Iterable.where

Implementation

Map<K, V> where(bool Function(K key, V value) predicate) {
  return Map.fromEntries(entries.where((entry) => predicate(entry.key, entry.value)));
}