mutate method

void mutate(
  1. void mutator(
    1. Map<K, V> map
    )
)

Mutate the map in-place and notify listeners.

High performance alternative for massive maps. Bypasses object allocation and equality checks.

Implementation

void mutate(void Function(Map<K, V> map) mutator) {
  mutator(value);
  notifyListeners();
}