Total Complexity | 4 |
Total Lines | 30 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
17 | class RoleManager |
||
18 | { |
||
19 | /** |
||
20 | * @var AbstractRole[] |
||
21 | */ |
||
22 | const ROLES = [ |
||
23 | MemberRole::class, |
||
24 | ScripterRole::class, |
||
25 | GuestRole::class, |
||
26 | AdminRole::class |
||
27 | ]; |
||
28 | |||
29 | public static function member(): MemberRole |
||
30 | { |
||
31 | return MemberRole::singleton(); |
||
32 | } |
||
33 | |||
34 | public static function scripter(): ScripterRole |
||
35 | { |
||
36 | return ScripterRole::singleton(); |
||
37 | } |
||
38 | |||
39 | public static function admin(): AdminRole |
||
42 | } |
||
43 | |||
44 | public static function guest(): GuestRole |
||
47 | } |
||
48 | } |
||
49 |