1 | <?php |
||
12 | class GateRegistrar |
||
13 | { |
||
14 | /** |
||
15 | * @var GateContract |
||
16 | */ |
||
17 | private $gate; |
||
18 | |||
19 | /** |
||
20 | * @var Repository |
||
21 | */ |
||
22 | private $cache; |
||
23 | |||
24 | /** |
||
25 | * GateRegistrar constructor. |
||
26 | * |
||
27 | * @param GateContract $gate |
||
28 | * @param Repository $cache |
||
29 | */ |
||
30 | public function __construct(GateContract $gate, Repository $cache) |
||
35 | |||
36 | /** |
||
37 | * Handle permission gate registration. |
||
38 | */ |
||
39 | public function register() |
||
55 | |||
56 | /** |
||
57 | * Get all permissions. |
||
58 | * |
||
59 | * @return Collection |
||
60 | */ |
||
61 | protected function getPermissions(): Collection |
||
78 | |||
79 | /** |
||
80 | * @return Permission |
||
81 | */ |
||
82 | protected function getPermissionClass(): Permission |
||
86 | } |
||
87 |