Migration class

A Migration is an action that modifies a schema or database. Note, schema here does not refer to the schema object, but rather a schema that is used for data persistence.

Inheritance

Constructors

Migration(String name, Future<void> migrationAction(Object?))
Migration.fromDb({required int? id, required String name, DateTime? start, DateTime? finish, required MigrationState migrationState})

Properties

finish DateTime?
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
id int?
/////////////////////////////////////////////////////////////////////////
getter/setter pair
migrationAction Future<void> Function(Object?)
getter/setter pair
migrationState MigrationState
getter/setter pair
name String
getter/setter pair
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
start DateTime?
getter/setter pair
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited

Methods

become(Migration migration) → void
compareTo(Migration other) int
Compares this object to another object.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toColumns(bool nullToAbsent) Map<String, Expression<Object>>
/////////////////////////////////////////////////////////////////////////
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

resetMigrationRegistry() → void