Grammar
Extends
Uses
Properties
$modifiers string[]
The possible column modifiers.
$transactions bool
If this Grammar supports schema changes wrapped in a transaction.
$fluentCommands array
The commands to be executed outside of create or alter command.
Methods
compileCreateDatabase ( $name , $connection ) : void
Compile a create database command.
Parameters
- $name string
- $connection Connection
compileDropDatabaseIfExists ( $name ) : void
Compile a drop database if exists command.
Parameters
- $name string
compileRenameColumn ( Blueprint $blueprint , Illuminate\...\Fluent $command , Connection $connection ) : array|string
Compile a rename column command.
Parameters
- $blueprint Blueprint
- $command Illuminate\...\Fluent
- $connection Connection
compileChange ( Blueprint $blueprint , Illuminate\...\Fluent $command , Connection $connection ) : array|string
Compile a change column command into a series of SQL statements.
Parameters
- $blueprint Blueprint
- $command Illuminate\...\Fluent
- $connection Connection
compileFulltext ( Blueprint $blueprint , Illuminate\...\Fluent $command ) : string
Compile a fulltext index key command.
Parameters
- $blueprint Blueprint
- $command Illuminate\...\Fluent
compileDropFullText ( Blueprint $blueprint , Illuminate\...\Fluent $command ) : string
Compile a drop fulltext index command.
Parameters
- $blueprint Blueprint
- $command Illuminate\...\Fluent
compileForeign ( Blueprint $blueprint , Illuminate\...\Fluent $command ) : string
Compile a foreign key command.
Parameters
- $blueprint Blueprint
- $command Illuminate\...\Fluent
getColumns ( Blueprint $blueprint ) : array
Compile the blueprint's added column definitions.
Parameters
- $blueprint Blueprint
getType ( Illuminate\...\Fluent $column ) : string
Get the SQL for the column data type.
Parameters
- $column Illuminate\...\Fluent
typeComputed ( Illuminate\...\Fluent $column ) : void
Create the column definition for a generated, computed column type.
Parameters
- $column Illuminate\...\Fluent
addModifiers ( $sql , Blueprint $blueprint , Illuminate\...\Fluent $column ) : string
Add the column modifiers to the definition.
Parameters
- $sql string
- $blueprint Blueprint
- $column Illuminate\...\Fluent
getCommandByName ( Blueprint $blueprint , $name ) : Illuminate\...\Fluent|null
Get the primary key command if it exists on the blueprint.
Parameters
- $blueprint Blueprint
- $name string
getCommandsByName ( Blueprint $blueprint , $name ) : array
Get all of the commands with a given name.
Parameters
- $blueprint Blueprint
- $name string
prefixArray ( $prefix , array $values ) : array
Add a prefix to an array of values.
Parameters
- $prefix string
- $values array
wrapTable ( $table ) : string
Wrap a table in keyword identifiers.
Parameters
- $table mixed
wrap ( $value , $prefixAlias ) : string
Wrap a value in keyword identifiers.
Parameters
- $value Illuminate\...\Fluent|Expression |string
- $prefixAlias bool
getDefaultValue ( $value ) : string
Format a value so that it can be used in "default" clauses.
Parameters
- $value mixed
getDoctrineTableDiff ( Blueprint $blueprint , Doctrine\...\AbstractSchemaManager $schema ) : Doctrine\...\TableDiff
Create an empty Doctrine DBAL TableDiff from the Blueprint.
Parameters
- $blueprint Blueprint
- $schema Doctrine\...\AbstractSchemaManager
getFluentCommands ( ) : array
Get the fluent commands for the grammar.
supportsSchemaTransactions ( ) : bool
Check if this Grammar supports schema changes wrapped in a transaction.