save abstract method

Future<void> save(
  1. Snapshot snapshot, [
  2. String? key
])

Saves a snapshot to storage.

Parameters:

  • snapshot: The snapshot to save
  • key: Optional key/identifier for the snapshot. If not provided, a default key will be used.

Returns: A Future that completes when the snapshot is saved.

Throws:

  • Storage-specific exceptions (e.g., IOException for file storage)

Implementation

Future<void> save(Snapshot snapshot, [String? key]);