메소드 | 설명 | |
---|---|---|
__construct ( |
||
__toString ( ) | ||
addSql ( array | string $sql, array $params = [], array $types = [] ) | Add some SQL queries to this versions migration | |
execute ( string $direction, boolean $dryRun = false, boolean $timeAllQueries = false ) : array | Execute this migration version up or down and and return the SQL. | |
getConfiguration ( ) : |
Returns the Migrations Configuration object instance | |
getExecutionState ( ) | ||
getMigration ( ) : Doctrine\DBAL\Migrations\AbstractMigration | ||
getTime ( ) : integer | Returns the time this migration version took to execute | |
getVersion ( ) : string | Returns the string version in the format YYYYMMDDHHMMSS | |
isMigrated ( ) : boolean | Check if this version has been migrated or not. | |
markMigrated ( ) | ||
markNotMigrated ( ) | ||
writeSqlFile ( string $path, string $direction = self::DIRECTION_UP ) : boolean | Write a migration SQL file to the given path |
메소드 | 설명 | |
---|---|---|
addQueryParams ( mixed[] $params, string[] $types ) | ||
executeRegisteredSql ( $dryRun = false, $timeAllQueries = false ) | ||
formatParamsForOutput ( array $params, array $types ) : string | null | Formats a set of sql parameters for output with dry run. | |
markVersion ( $direction ) | ||
outputQueryTime ( $queryStart, $timeAllQueries = false ) | ||
outputSqlQuery ( integer $idx, string $query ) : void | Outputs a SQL query via the OutputWriter. |
public __construct ( |
||
$configuration | ||
$schemaProvider | Doctrine\DBAL\Migrations\Provider\SchemaDiffProviderInterface |
public execute ( string $direction, boolean $dryRun = false, boolean $timeAllQueries = false ) : array | ||
$direction | string | The direction to execute the migration. |
$dryRun | boolean | Whether to not actually execute the migration SQL and just do a dry run. |
$timeAllQueries | boolean | Measuring or not the execution time of each SQL query. |
리턴 | array | $sql |
public getConfiguration ( ) : |
||
리턴 | $configuration |
public getMigration ( ) : Doctrine\DBAL\Migrations\AbstractMigration | ||
리턴 | Doctrine\DBAL\Migrations\AbstractMigration |
public getVersion ( ) : string | ||
리턴 | string | $version |
public isMigrated ( ) : boolean | ||
리턴 | boolean |