| Total Complexity | 5 |
| Total Lines | 63 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | class StateChange implements \JsonSerializable |
||
| 13 | { |
||
| 14 | |||
| 15 | const STATE_SUBSCRIPTION_STARTED = 'started'; |
||
| 16 | const STATE_SUBSCRIPTION_STOPPED = 'stopped'; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @var int |
||
| 20 | */ |
||
| 21 | private $_subscriptionId; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var string |
||
| 25 | */ |
||
| 26 | private $_state; |
||
| 27 | |||
| 28 | |||
| 29 | /** |
||
| 30 | * StateChange constructor |
||
| 31 | * |
||
| 32 | * @param int $subscriptionId |
||
| 33 | */ |
||
| 34 | 2 | public function __construct($subscriptionId) |
|
| 35 | { |
||
| 36 | 2 | $this->_subscriptionId = $subscriptionId; |
|
| 37 | 2 | } |
|
| 38 | |||
| 39 | |||
| 40 | /** |
||
| 41 | * @return int |
||
| 42 | */ |
||
| 43 | 2 | public function getSubscriptionId() |
|
| 44 | { |
||
| 45 | 2 | return $this->_subscriptionId; |
|
| 46 | } |
||
| 47 | |||
| 48 | |||
| 49 | /** |
||
| 50 | * @return string |
||
| 51 | */ |
||
| 52 | 2 | public function getState() |
|
| 55 | } |
||
| 56 | |||
| 57 | |||
| 58 | /** |
||
| 59 | * @param string $state |
||
| 60 | */ |
||
| 61 | 2 | public function setState($state) |
|
| 62 | { |
||
| 63 | 2 | $this->_state = $state; |
|
| 64 | 2 | } |
|
| 65 | |||
| 66 | |||
| 67 | /** |
||
| 68 | * @inheritdoc |
||
| 69 | */ |
||
| 70 | 2 | public function jsonSerialize() |
|
| 75 | 2 | ]; |
|
| 76 | } |
||
| 77 | |||
| 78 | } |
||
| 79 |