Automattic\WooCommerce\Internal\ProductFeed\Integrations\POSCatalog
AsyncGenerator::apply_mapper_args
Applies the dynamic field arguments to the product mapper.
Метод класса: AsyncGenerator{}
Хуков нет.
Возвращает
void. Ничего (null).
Использование
// private - только в коде основоного (родительского) класса $result = $this->apply_mapper_args( $args ): void;
- $args(массив) (обязательный)
- The feed generation arguments.
Код AsyncGenerator::apply_mapper_args() AsyncGenerator::apply mapper args WC 11.2.2
private function apply_mapper_args( array $args ): void {
if ( isset( $args['_product_fields'] ) && is_string( $args['_product_fields'] ) && '' !== $args['_product_fields'] ) {
$this->integration->get_product_mapper()->set_fields( $args['_product_fields'] );
}
if ( isset( $args['_variation_fields'] ) && is_string( $args['_variation_fields'] ) && '' !== $args['_variation_fields'] ) {
$this->integration->get_product_mapper()->set_variation_fields( $args['_variation_fields'] );
}
}