clear method

  1. @override
void clear()
override

Removes all entries from the map.

Clears all key-value pairs and notifies subscribers of the change.

Implementation

@override
void clear() {
  if (peek.isEmpty) {
    return;
  } else {
    peek.clear();
    notify(true);
  }
}