Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
getAliases () | |
apply () | |
Static Public Member Functions | |
static | getDependencies () |
static | getVersion () |
Definition at line 35 of file data_patch_classes.php.
apply | ( | ) |
{Run code inside patch If code fails, patch must be reverted, in case when we are speaking about schema - than under revert means run PatchInterface::revert()If we speak about data, under revert means: $transaction->rollback()
Implements PatchInterface.
Definition at line 60 of file data_patch_classes.php.
getAliases | ( | ) |
{Get aliases (previous names) for the patch.
Implements PatchInterface.
Definition at line 52 of file data_patch_classes.php.
|
static |
{Get array of patches that have to be executed prior to this.example of implementation:[ \Vendor_Name\Module_Name\Setup\Patch\Patch1::class, \Vendor_Name\Module_Name\Setup\Patch\Patch2::class ]
Implements DependentPatchInterface.
Definition at line 42 of file data_patch_classes.php.
|
static |
{This version associate patch with Magento setup version. For example, if Magento current setup version is 2.0.3 and patch version is 2.0.2 than this patch will be added to registry, but will not be applied, because it is already applied by old mechanism of UpgradeData.php script
Implements PatchVersionInterface.
Definition at line 68 of file data_patch_classes.php.