Automattic\WooCommerce\Blueprint
ImportStep::__construct
ImportStep constructor.
Метод класса: ImportStep{}
Хуки из метода
Возвращает
null. Ничего (null).
Использование
$ImportStep = new ImportStep(); $ImportStep->__construct( $step_definition, ?Validator $validator );
- $step_definition(объект) (обязательный)
- The step definition.
- ?Validator $validator
- .
По умолчанию:null
Код ImportStep::__construct() ImportStep:: construct WC 10.7.0
public function __construct( $step_definition, ?Validator $validator = null ) {
$this->step_definition = $step_definition;
if ( null === $validator ) {
$validator = new Validator();
}
$this->validator = $validator;
$this->importers = $this->wp_apply_filters( 'wooblueprint_importers', ( ( new BuiltInStepProcessors() )->get_all() ) );
$this->indexed_importers = Util::index_array(
$this->importers,
function ( $key, $importer ) {
return $importer->get_step_class()::get_step_name();
}
);
}