Total Complexity | 3 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
5 | trait HasType |
||
6 | { |
||
7 | /** |
||
8 | * @var string |
||
9 | */ |
||
10 | protected $type; |
||
11 | |||
12 | /** |
||
13 | * @param string $type |
||
14 | * |
||
15 | * @return $this |
||
16 | */ |
||
17 | 200 | public function setType(string $type) |
|
18 | { |
||
19 | 200 | $this->type = $type; |
|
20 | |||
21 | 200 | return $this; |
|
22 | } |
||
23 | |||
24 | /** |
||
25 | * @return string |
||
26 | */ |
||
27 | 215 | public function getType(): string |
|
30 | } |
||
31 | |||
32 | /** |
||
33 | * @return bool |
||
34 | */ |
||
35 | 35 | public function hasType(): bool |
|
40 |