abstract class Migration
Migration factory.
Implements some handy shortcuts for creating typical migrations.
Methods
static array
createTable(string $name, callable $definition, callable|bool|null $shouldRun = null)
No description
static array
createTableIfNotExists(string $name, callable $definition, callable|bool|null $shouldRun = null)
No description
static array
renameTable(string $from, string $to, callable|bool|null $shouldRun = null)
No description
static array
addColumns(string $tableName, array $columnDefinitions, callable|bool|null $shouldRun = null)
No description
static array
dropColumns(string $tableName, array $columnDefinitions, callable|bool|null $shouldRun = null)
No description
static array
renameColumn(string $tableName, string $from, string $to, callable|bool|null $shouldRun = null)
No description
static array
renameColumns(string $tableName, array $columnNames, callable|bool|null $shouldRun = null)
No description
static array
addSettings(array $defaults, callable|bool|null $shouldRun = null)
Add default values for config values.
static array
addPermissions(array $permissions, callable|bool|null $shouldRun = null)
No description
Details
at
line 24
static array
createTable(string $name, callable $definition, callable|bool|null $shouldRun = null)
at
line 39
static array
createTableIfNotExists(string $name, callable $definition, callable|bool|null $shouldRun = null)
at
line 56
static array
renameTable(string $from, string $to, callable|bool|null $shouldRun = null)
at
line 69
static array
addColumns(string $tableName, array $columnDefinitions, callable|bool|null $shouldRun = null)
at
line 89
static array
dropColumns(string $tableName, array $columnDefinitions, callable|bool|null $shouldRun = null)
at
line 100
static array
renameColumn(string $tableName, string $from, string $to, callable|bool|null $shouldRun = null)
at
line 105
static array
renameColumns(string $tableName, array $columnNames, callable|bool|null $shouldRun = null)
at
line 132
static array
addSettings(array $defaults, callable|bool|null $shouldRun = null)
Add default values for config values.
You generally should use the Settings extender's `default` method instead to register settings.