Interface yii\db\MigrationInterface

Implemented bylispa\amos\core\migration\AmosMigration, lispa\amos\core\migration\AmosMigrationPermissions, lispa\amos\core\migration\AmosMigrationTableCreation, lispa\amos\core\migration\AmosMigrationTranslations, lispa\amos\core\migration\AmosMigrationWidgets, lispa\amos\core\migration\AmosMigrationWorkflow, yii\db\Migration
Available since version2.0
Source Code https://github.com/yiisoft/yii2/blob/master/framework/db/MigrationInterface.php

The MigrationInterface defines the minimum set of methods to be implemented by a database migration.

Each migration class should provide the up() method containing the logic for "upgrading" the database and the down() method for the "downgrading" logic.

Public Methods

Hide inherited methods

MethodDescriptionDefined By
down() This method contains the logic to be executed when removing this migration. yii\db\MigrationInterface
up() This method contains the logic to be executed when applying this migration. yii\db\MigrationInterface

Method Details

down() public abstract method

This method contains the logic to be executed when removing this migration.

The default implementation throws an exception indicating the migration cannot be removed.

public abstract boolean down ( )
return boolean

Return a false value to indicate the migration fails and should not proceed further. All other return values mean the migration succeeds.

up() public abstract method

This method contains the logic to be executed when applying this migration.

public abstract boolean up ( )
return boolean

Return a false value to indicate the migration fails and should not proceed further. All other return values mean the migration succeeds.