difference method

Map<K, V> Function(Map<K, V> map) difference(
  1. Eq<K> eq
)

Remove from this Map all the elements that have key contained in the given map.

Implementation

Map<K, V> Function(Map<K, V> map) difference(Eq<K> eq) =>
    (Map<K, V> map) => filterWithKey(
          (key, value) => !map.keys.any((element) => eq.eqv(element, key)),
        );