migration library

Reviewed, engine-specific Dart migrations and transactional application.

Classes

Migration
A reviewed migration saved as Dart source, independent of application types.
MigrationHistory
Ordered static registration of immutable migrations for one engine.
MigrationPlan
SQL for a reviewed schema transition on one database engine.
MigrationRunner
Applies a static migration history through the database's owned transaction.

Functions

freezeSnapshot(SchemaSnapshot snapshot) → SchemaSnapshot
Copies and validates a snapshot without retaining mutable application data.
migrationFingerprint({required int version, required String name, required Engine engine, required List<String> steps, required SchemaSnapshot snapshot}) → String
Calculates the fingerprint to paste into a reviewed Dart migration file.
planSchemaChange(SchemaSnapshot before, SchemaSnapshot after) → MigrationPlan
Plans conservative additions between two complete frozen snapshots.