clear method

void clear()

Clears entries, in-flight trackers, and controllers within this scope.

The scope remains usable after clear (unlike dispose).

Implementation

void clear() {
  if (_disposed) return;
  _cache.clear();
  for (final ctrl in _invalidationControllers.values) {
    try {
      ctrl.close();
    } catch (_) {}
  }
  _invalidationControllers.clear();
  _inFlightRequests.clear();
}