예제 #1
0
파일: Controller.php 프로젝트: vbryan/Zend
 public function preDispatch()
 {
     $controller = $this->getActionController();
     $controllerName = get_class($controller);
     if ($this->serviceManager->has($controllerName)) {
         $this->serviceManager->setService('controller', $controller);
         if (!$this->serviceManager->get($controllerName)) {
             throw new \Exception('Invalid Controller');
         }
     }
 }