EqualityMap<K, V>.from constructor Null safety

EqualityMap<K, V>.from(
  1. Equality<K> equality,
  2. Map<K, V> other

Creates a map with equality based on equality that contains all key-value pairs of other.

If other has multiple keys that are equivalent according to equality, the last one reached during iteration takes precedence.


EqualityMap.from(Equality<K> equality, Map<K, V> other)
    : super(LinkedHashMap(
          equals: equality.equals,
          hashCode: equality.hash,
          isValidKey: equality.isValidKey)) {