1 | <?php |
||
6 | class ControllerPoint extends AbstractPoint |
||
7 | { |
||
8 | protected $controller; |
||
9 | protected $action; |
||
10 | |||
11 | /** |
||
12 | * @param Route $route |
||
13 | * @param array $args |
||
14 | * |
||
15 | * @return mixed |
||
16 | */ |
||
17 | public function __invoke(Route $route, array $args = []) |
||
22 | |||
23 | /** |
||
24 | * @param Route $route |
||
25 | * @return callable |
||
26 | */ |
||
27 | protected function getPoint(Route $route) |
||
40 | |||
41 | /** |
||
42 | * @return string |
||
43 | */ |
||
44 | protected function getControllerClass() : string |
||
48 | |||
49 | /** |
||
50 | * @param $controller |
||
51 | * @throws \BadMethodCallException |
||
52 | */ |
||
53 | protected function checkController($controller) |
||
59 | |||
60 | /** |
||
61 | * @param $controller |
||
62 | * @param string $action |
||
63 | * @throws \BadMethodCallException |
||
64 | */ |
||
65 | protected function checkAction($controller, $action) |
||
71 | |||
72 | /** |
||
73 | * @param array $matches |
||
74 | * @return string |
||
75 | */ |
||
76 | protected function getAction(array $matches = []) : string |
||
80 | |||
81 | } |
||
82 |