public function setRequest(Request $request)
    {
        $this->request = $request;
        $this->app = null;
        $this->vhost = null;
        $this->route = null;
        $this->setVariable('request', $request);
        return $this;
    }