\Phinx\MigrationCreationInterface

Migration interface

Summary

Methods
Constants
__construct()
setInput()
setOutput()
getInput()
getOutput()
getMigrationTemplate()
postMigrationCreation()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

__construct()

__construct(\think\console\Input|null  $input = null, \think\console\Output|null  $output = null) 

CreationInterface constructor.

Parameters

\think\console\Input|null $input
\think\console\Output|null $output

getMigrationTemplate()

getMigrationTemplate() : string

Get the migration template.

This will be the content that Phinx will amend to generate the migration file.

Returns

string —

The content of the template for Phinx to amend.

postMigrationCreation()

postMigrationCreation(string  $migrationFilename, string  $className, string  $baseClassName) : void

Post Migration Creation.

Once the migration file has been created, this method will be called, allowing any additional processing, specific to the template to be performed.

Parameters

string $migrationFilename

The name of the newly created migration.

string $className

The class name.

string $baseClassName

The name of the base class.