public function setController(Controller $controller) { $this->controller = $controller; if (method_exists($this->renderer, 'setController')) { $this->renderer->setController($controller); } }
public final function __construct() { $this->data = new Std(); $this->app = Application::getInstance(); $this->view = new View('twig', $this->getTemplatePaths()); $this->view->setController($this); }