SchemaGrammar class abstract
Turns a Blueprint into DDL for one dialect. The defaults here are the ANSI-ish subset SQLite and PostgreSQL share; adapters override type names, literals and the catalogue queries.
- Implementers
Constructors
- SchemaGrammar()
-
const
Properties
Methods
-
boolLiteral(
bool value) → String -
How a
booldefault is written. -
compileAlter(
Blueprint blueprint) → List< String> - One statement per added column, column index and command.
-
compileColumn(
ColumnDefinition column) → String -
compileColumnListing(
String table) → Compiled -
(sql, bindings)returning anamecolumn per column oftable. -
compileCommand(
String table, SchemaCommand command) → String -
compileCreate(
Blueprint blueprint) → List< String> - One CREATE TABLE followed by a CREATE INDEX per index.
-
compileDefault(
Object? value) → String -
compileDrop(
String table) → String -
compileDropIfExists(
String table) → String -
compileIndex(
String table, IndexCommand index) → String -
compileRename(
String from, String to) → String -
compileTableExists(
) → Compiled -
(sql, bindings)selecting one row when the bound table name exists. -
compileTableListing(
) → String -
SQL selecting every user table name in the database (one column, no
bindings) — used by
Schema.dropAllTables. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
typeFor(
ColumnDefinition column) → String -
The SQL type for
column. -
wrap(
String identifier) → String - Double-quotes an identifier (each dotted segment separately).
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited