clear method

  1. @override
Future<void> clear()
override

Clears all key value pairs from storage.

Implementation

@override
Future<void> clear() {
  _checkOpen('clear');
  // Suspend the live stores now: a write they queued behind the lock
  // would otherwise land after the wipe.
  HydratedMobX.suspendAll(storage: this);
  return _pending.clear(
    () => _locked('clear', () => _deleteFiles(_keys.toList())),
  );
}