/** * @param RouteParameter $Route * * @throws ComponentException * @return callable */ private function handleController(RouteParameter $Route) { $Class = $Route->getClass(); if (!class_exists($Class, true)) { // @codeCoverageIgnoreStart throw new ComponentException($Class); // @codeCoverageIgnoreEnd } $Method = $Route->getMethod(); $Object = new $Class(); if (!method_exists($Object, $Method)) { // @codeCoverageIgnoreStart throw new ComponentException($Method); // @codeCoverageIgnoreEnd } return array($Object, $Method); }