| Total Complexity | 6 |
| Total Lines | 40 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | trait EventBehavior |
||
| 12 | { |
||
| 13 | private Graph $graph; |
||
| 14 | private object $object; |
||
| 15 | private Transition $transition; |
||
| 16 | private State $fromState; |
||
| 17 | private State $toState; |
||
| 18 | |||
| 19 | 7 | public function __construct(Graph $graph, object $object, Transition $transition, State $fromState, State $toState) |
|
| 20 | { |
||
| 21 | 7 | $this->graph = $graph; |
|
| 22 | 7 | $this->object = $object; |
|
| 23 | 7 | $this->transition = $transition; |
|
| 24 | 7 | $this->fromState = $fromState; |
|
| 25 | 7 | $this->toState = $toState; |
|
| 26 | 7 | } |
|
| 27 | |||
| 28 | 1 | public function graph(): Graph |
|
| 29 | { |
||
| 30 | 1 | return $this->graph; |
|
| 31 | } |
||
| 32 | |||
| 33 | 7 | public function object(): object |
|
| 34 | { |
||
| 35 | 7 | return $this->object; |
|
| 36 | } |
||
| 37 | |||
| 38 | 7 | public function transition(): Transition |
|
| 39 | { |
||
| 40 | 7 | return $this->transition; |
|
| 41 | } |
||
| 42 | |||
| 43 | 7 | public function fromState(): State |
|
| 46 | } |
||
| 47 | |||
| 48 | 7 | public function toState(): State |
|
| 51 | } |
||
| 52 | } |
||
| 53 |