Migrate
class Migrate
Helper class for migration related console commands.
Constants
| MIGRATIONS_PATH |
Path to database migration files. |
Methods
Test if a particular batch of migrations exists.
Drops all tables from the database without using down function.
Generates time stamp for migrations in following format: yyyymmddhhmmss.
Generates migration for acl table.
Generates all migrations.
Generates migration for email_attachments table.
Generates migration by name.
Generates migration for migration table.
Generates migration for profile_images table.
Generates migration for user_sessions table.
Generates migration for users table.
Generates a migration class for creating a new table.
Generates a migration class for renaming an existing table.
Generates a migration class for updating existing table.
Performs migration operation.
Performs refresh operation.
Performs roll back operation
Perform step roll back.
Reports migration status.
Drops table one at a time.
Determines number of tables in database before performing migration operations.
Details
at line 31
static private bool
batchExists(int $batch)
Test if a particular batch of migrations exists.
at line 45
static int
dropAllTables()
Drops all tables from the database without using down function.
at line 78
static string
fileNameTime()
Generates time stamp for migrations in following format: yyyymmddhhmmss.
at line 87
static int
generateACLTableMigration()
Generates migration for acl table.
at line 101
static int
generateAllMigrations()
Generates all migrations.
at line 115
static int
generateEmailAttachmentsTableMigration()
Generates migration for email_attachments table.
at line 130
static int
generateMigrationByName(InputInterface $input)
Generates migration by name.
at line 145
static int
generateMigrationsTableMigration()
Generates migration for migration table.
at line 159
static int
generateProfileImagesTableMigration()
Generates migration for profile_images table.
at line 173
static int
generateUserSessionsTableMigration()
Generates migration for user_sessions table.
at line 187
static int
generateUsersTableMigration()
Generates migration for users table.
at line 202
static int
makeMigration(InputInterface $input)
Generates a migration class for creating a new table.
at line 220
static int
makeRenameMigration(InputInterface $input)
Generates a migration class for renaming an existing table.
at line 239
static int
makeUpdateMigration(InputInterface $input)
Generates a migration class for updating existing table.
at line 256
static int
migrate()
Performs migration operation.
at line 328
static int
refresh(bool|int $step = false)
Performs refresh operation.
at line 383
static int
rollback(string|int|bool $batch = false)
Performs roll back operation
at line 431
static int
rollbackStep(string|int $step)
Perform step roll back.
at line 444
static int
status()
Reports migration status.
at line 500
static private bool|int
step(string $klassNamespace, bool|int $step = false)
Drops table one at a time.
at line 521
static private int
tableCount()
Determines number of tables in database before performing migration operations.