1 | <?php |
||
21 | class ControllerInvoker implements ControllerInvokerInterface |
||
22 | { |
||
23 | |||
24 | /** |
||
25 | * @var ContainerInterface |
||
26 | */ |
||
27 | private $container; |
||
28 | |||
29 | /** |
||
30 | * Creates a Controller Invoker |
||
31 | * |
||
32 | * @param ContainerInterface $container |
||
33 | */ |
||
34 | public function __construct(ContainerInterface $container) |
||
38 | |||
39 | /** |
||
40 | * Invokes the controller action returning view data |
||
41 | * |
||
42 | * @param ControllerContextInterface $context |
||
43 | * @param ControllerDispatch $dispatch |
||
44 | * |
||
45 | * @return array |
||
46 | */ |
||
47 | public function invoke( |
||
60 | |||
61 | /** |
||
62 | * Uses the dependency container to create the controller |
||
63 | * |
||
64 | * @param \ReflectionClass $controllerName |
||
65 | * |
||
66 | * @return ControllerInterface |
||
67 | */ |
||
68 | private function createController(\ReflectionClass $controllerName) |
||
73 | } |
||
74 |