/** * @return Response */ public function getResponse() { if (null !== $this->response) { $this->response->setPublic(); $this->response->setPrivate(); $this->response->setMaxAge($this->configuration->getTtl()); $this->response->setSharedMaxAge($this->configuration->getTtl()); $this->response->setCharset('UTF-8'); $this->response->prepare($this->request); return $this->response; } else { throw new \RuntimeException("Request had not been handled. Use handle() method before getResponse()", 1); } }