/** * Initializes a new coupon provider object using the given context object. * * @param MShop_Context_Item_Interface $context Context object with required objects * @param MShop_Coupon_Item_Interface $couponItem Coupon item with configuration for the provider * @param string $code Coupon code entered by the customer */ public function __construct(MShop_Context_Item_Interface $context, MShop_Coupon_Item_Interface $couponItem, $code, MShop_Coupon_Provider_Interface $provider) { $this->_provider = $provider; parent::__construct($context, $couponItem, $code); }
/** * Initializes the object instance * * PHP 7 fails with a wierd fatal error that decorator constructors must be * compatible with the constructor of the factory interface if this * intermediate constructor isn't implemented! * * @param MShop_Context_Item_Interface $context Context object * @param MShop_Coupon_Item_Interface $item Coupon item * @param string $code Coupon code entered by the customer */ public function __construct(MShop_Context_Item_Interface $context, MShop_Coupon_Item_Interface $item, $code) { parent::__construct($context, $item, $code); }