PHP 클래스 Horde_Db_Migration_Migrator, horde

저자: Mike Naberezny ([email protected])
저자: Derek DeVries ([email protected])
저자: Chuck Hagenbuch ([email protected])
파일 보기 프로젝트 열기: horde/horde 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$_direction string
$_migrationsPath string
$_schemaTableName string
$_targetVersion integer

공개 메소드들

메소드 설명
__construct ( Horde_Db_Adapter $connection, Horde_Log_Logger $logger = null, array $options = [] ) Constructor.
down ( string $targetVersion = null )
getCurrentVersion ( ) : integer
getTargetVersion ( ) : integer
migrate ( string $targetVersion = null )
setInflector ( Horde_Support_Inflector $inflector )
setLogger ( Horde_Log_Logger $logger )
setMigrationsPath ( string $migrationsPath )
up ( string $targetVersion = null )

보호된 메소드들

메소드 설명
_assertUniqueMigrationVersion ( array $migrations, integer $version )
_doMigrate ( ) Performs the migration.
_getMigrationClass ( string $migrationName, integer $version ) : Horde_Db_Migration_Base Actually returns object, and not class.
_getMigrationClasses ( ) : array
_getMigrationFiles ( ) : array Returns the list of migration files.
_getMigrationVersionAndName ( string $migrationFile ) : array
_hasReachedTargetVersion ( $version ) : boolean
_initializeSchemaInformation ( )
_isDown ( ) : boolean
_isIrrelevantMigration ( integer $version ) : boolean
_isUp ( ) : boolean
_setSchemaVersion ( integer $version )

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( Horde_Db_Adapter $connection, Horde_Log_Logger $logger = null, array $options = [] )
$connection Horde_Db_Adapter A DB connection object.
$logger Horde_Log_Logger A logger object.
$options array Additional options for the migrator: - migrationsPath: directory with the migration files. - schemaTableName: table for storing the schema version.

_assertUniqueMigrationVersion() 보호된 메소드

protected _assertUniqueMigrationVersion ( array $migrations, integer $version )
$migrations array
$version integer

_doMigrate() 보호된 메소드

Performs the migration.
protected _doMigrate ( )

_getMigrationClass() 보호된 메소드

Actually returns object, and not class.
protected _getMigrationClass ( string $migrationName, integer $version ) : Horde_Db_Migration_Base
$migrationName string
$version integer
리턴 Horde_Db_Migration_Base

_getMigrationClasses() 보호된 메소드

protected _getMigrationClasses ( ) : array
리턴 array

_getMigrationFiles() 보호된 메소드

Returns the list of migration files.
protected _getMigrationFiles ( ) : array
리턴 array

_getMigrationVersionAndName() 보호된 메소드

protected _getMigrationVersionAndName ( string $migrationFile ) : array
$migrationFile string
리턴 array ($version, $name)

_hasReachedTargetVersion() 보호된 메소드

protected _hasReachedTargetVersion ( $version ) : boolean
리턴 boolean

_initializeSchemaInformation() 보호된 메소드

_isDown() 보호된 메소드

protected _isDown ( ) : boolean
리턴 boolean

_isIrrelevantMigration() 보호된 메소드

protected _isIrrelevantMigration ( integer $version ) : boolean
$version integer
리턴 boolean

_isUp() 보호된 메소드

protected _isUp ( ) : boolean
리턴 boolean

_setSchemaVersion() 보호된 메소드

protected _setSchemaVersion ( integer $version )
$version integer

down() 공개 메소드

public down ( string $targetVersion = null )
$targetVersion string

getCurrentVersion() 공개 메소드

public getCurrentVersion ( ) : integer
리턴 integer

getTargetVersion() 공개 메소드

public getTargetVersion ( ) : integer
리턴 integer

migrate() 공개 메소드

public migrate ( string $targetVersion = null )
$targetVersion string

setInflector() 공개 메소드

public setInflector ( Horde_Support_Inflector $inflector )
$inflector Horde_Support_Inflector

setLogger() 공개 메소드

public setLogger ( Horde_Log_Logger $logger )
$logger Horde_Log_Logger

setMigrationsPath() 공개 메소드

public setMigrationsPath ( string $migrationsPath )
$migrationsPath string Path to migration files.

up() 공개 메소드

public up ( string $targetVersion = null )
$targetVersion string

프로퍼티 상세

$_direction 보호되어 있는 프로퍼티

protected string $_direction
리턴 string

$_migrationsPath 보호되어 있는 프로퍼티

protected string $_migrationsPath
리턴 string

$_schemaTableName 보호되어 있는 프로퍼티

protected string $_schemaTableName
리턴 string

$_targetVersion 보호되어 있는 프로퍼티

protected int $_targetVersion
리턴 integer