1 | <?php |
||
2 | |||
3 | namespace Terox\SubscriptionBundle\Event; |
||
4 | |||
5 | use Symfony\Component\EventDispatcher\Event; |
||
6 | use Terox\SubscriptionBundle\Model\SubscriptionInterface; |
||
7 | |||
8 | class SubscriptionEvent extends Event |
||
0 ignored issues
–
show
Deprecated Code
introduced
by
![]() |
|||
9 | { |
||
10 | /** |
||
11 | * @var SubscriptionInterface |
||
12 | */ |
||
13 | private $subscription; |
||
14 | |||
15 | /** |
||
16 | * @var bool |
||
17 | */ |
||
18 | private $fromRenew; |
||
19 | |||
20 | /** |
||
21 | * Constructor. |
||
22 | * |
||
23 | * @param SubscriptionInterface $subscription |
||
24 | * @param boolean $fromRenew |
||
25 | */ |
||
26 | 9 | public function __construct(SubscriptionInterface $subscription, $fromRenew = false) |
|
27 | { |
||
28 | 9 | $this->subscription = $subscription; |
|
29 | 9 | $this->fromRenew = $fromRenew; |
|
30 | 9 | } |
|
31 | |||
32 | /** |
||
33 | * @return SubscriptionInterface |
||
34 | */ |
||
35 | public function getSubscription() |
||
36 | { |
||
37 | return $this->subscription; |
||
38 | } |
||
39 | |||
40 | /** |
||
41 | * @return bool |
||
42 | */ |
||
43 | public function isFromRenew() |
||
44 | { |
||
45 | return $this->fromRenew; |
||
46 | } |
||
47 | } |
||
48 |