Beispiel #1
0
 /**
  * Starts and render the frame
  *
  * @param \Http\Request $_request HTTP Request handler
  * @param \Http\Response $_response HTTP Response handler
  * @param \View\Bridge $_view View engine
  */
 protected final function __construct(Request $_request, Response $_response, Bridge $_view)
 {
     Obj::$controller = $this;
     $this->_view = $_view;
     $this->_request = $_request;
     $this->_response = $_response;
     $this->_route = Obj::$router->route($_request);
     $this->_appDir = sprintf('%1$s/../../apps/%2$s', __DIR__, mb_strtolower($this->_route->app));
     $this->_config = is_dir($this->_appDir . '/conf') ? new Loader($this->_appDir . '/conf', Obj::$config->getEnv(), Obj::$config) : Obj::$config;
 }