SnapshotSaveOutcome

sealed interface SnapshotSaveOutcome

How the save of one snapshot of a SnapshotStore.saveAll ended: Written, Refused by the version guard (the store holds the same or a later version, or one of a higher state revision, which the save then marked stale), or Failed alone, the others of the batch unaffected. A failure of the whole call is thrown instead.

Inheritors

Types

Link copied to clipboard
Link copied to clipboard
class Failed @InternalWowApi constructor(val cause: Throwable) : SnapshotSaveOutcome

The store failed to save this snapshot alone (cause): a value it refuses, say. Whether it was written is not known; saving it again is safe, the save being version-guarded.

Link copied to clipboard

The version guard refused the snapshot, which is not an error.

Link copied to clipboard

The snapshot replaced the stored one, or there was none.

Properties

Link copied to clipboard
abstract val written: Boolean

Whether the snapshot was written: what SnapshotStore.save returns for it.