public function AddToCartLink::__construct in Commerce Add To Cart Link 8
Same name and namespace in other branches
- 2.x src/AddToCartLink.php \Drupal\commerce_add_to_cart_link\AddToCartLink::__construct()
Constructs a new AddToCartLink object.
Parameters
\Drupal\commerce_product\Entity\ProductVariationInterface $variation: The product variation.
File
- src/
AddToCartLink.php, line 28
Class
- AddToCartLink
- Defines a helper class for constructing add to cart links.
Namespace
Drupal\commerce_add_to_cart_linkCode
public function __construct(ProductVariationInterface $variation) {
$this->variation = $variation;
}