Total Complexity | 5 |
Total Lines | 41 |
Duplicated Lines | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
17 | trait HasStateParameter |
||
18 | { |
||
19 | /** |
||
20 | * @var bool |
||
21 | */ |
||
22 | protected $stateless = false; |
||
23 | |||
24 | /** |
||
25 | * @return $this |
||
26 | */ |
||
27 | public function stateless() |
||
32 | } |
||
33 | |||
34 | /** |
||
35 | * Generate state. |
||
36 | * |
||
37 | * @return string |
||
38 | */ |
||
39 | protected function makeState() |
||
43 | }); |
||
44 | } |
||
45 | |||
46 | /** |
||
47 | * @param string|null $state |
||
48 | * |
||
49 | * @return bool |
||
50 | */ |
||
51 | protected function hasValidState($state) |
||
60 |