Expand description
Schema migration system for save data.
MigrationRegistry holds an ordered chain of MigrationFn values keyed by
source version. migrate(data, from, to) runs the chain to bring save data
from any older version up to the current version without data loss.
Structs§
- Migration
Registry - Holds an ordered chain of migrations keyed by source version.
- Save
Data - Flexible key→value store that migrations read and modify.
- Schema
Version - A monotonically increasing version number for the save schema.
Enums§
- Save
Value - A flexible value type for use inside
SaveData.
Type Aliases§
- Migration
Fn - A function that transforms
SaveDatafrom version N to N+1.