Schema class
The Schema class provides a fluent way to manipulate your database tables.
It acts as a bridge between your migration definitions and the underlying database, handling the generation and execution of DDL (Data Definition Language) statements based on the database driver currently in use.
Constructors
- Schema(DatabaseAdapter _adapter)
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
create(
String table, void callback(Blueprint)) → Future< void> - Creates a brand new table in the database.
-
drop(
String table) → Future< void> - Permanently removes a table from the database.
-
dropIfExists(
String table) → Future< void> - Removes a table from the database only if it actually exists.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
table(
String table, void callback(Blueprint)) → Future< void> - Modifies an existing table's structure.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited