public function ProductVariationAttributeMapper::__construct in Commerce Core 8.2
Constructs a new ProductVariationAttributeMapper object.
Parameters
\Drupal\commerce_product\ProductAttributeFieldManagerInterface $attribute_field_manager: The attribute field manager.
\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.
\Drupal\Core\Entity\EntityRepositoryInterface $entity_repository: The entity repository.
File
- modules/
product/ src/ ProductVariationAttributeMapper.php, line 42
Class
Namespace
Drupal\commerce_productCode
public function __construct(ProductAttributeFieldManagerInterface $attribute_field_manager, EntityTypeManagerInterface $entity_type_manager, EntityRepositoryInterface $entity_repository) {
$this->attributeFieldManager = $attribute_field_manager;
$this->attributeStorage = $entity_type_manager
->getStorage('commerce_product_attribute');
$this->entityRepository = $entity_repository;
}