Automattic\WooCommerce\Blueprint
BuiltInStepProcessors{}
Class BuiltInStepProcessors
Хуков нет.
Использование
$BuiltInStepProcessors = new BuiltInStepProcessors(); // use class methods
Методы
- public __construct()
- public get_all()
- private create_install_plugins_processor()
- private create_install_themes_processor()
Заметки
- Пакет: Automattic\WooCommerce\Blueprint
Код BuiltInStepProcessors{} BuiltInStepProcessors{} WC 10.8.1
class BuiltInStepProcessors {
/**
* BuiltInStepProcessors constructor.
*/
public function __construct() {
}
/**
* Returns an array of all step processors.
*
* @return array The array of step processors.
*/
public function get_all() {
return array(
$this->create_install_plugins_processor(),
$this->create_install_themes_processor(),
new ImportSetSiteOptions(),
new ImportActivatePlugin(),
new ImportActivateTheme(),
new ImportRunSql(),
);
}
/**
* Creates the processor for installing plugins.
*
* @return ImportInstallPlugin The processor for installing plugins.
*/
private function create_install_plugins_processor() {
$storages = new ResourceStorages();
$storages->add_storage( new OrgPluginResourceStorage() );
return new ImportInstallPlugin( $storages );
}
/**
* Creates the processor for installing themes.
*
* @return ImportInstallTheme The processor for installing themes.
*/
private function create_install_themes_processor() {
$storage = new ResourceStorages();
$storage->add_storage( new OrgThemeResourceStorage() );
return new ImportInstallTheme( $storage );
}
}