/** Renders a response. */ public final function render(Response $response) { foreach ($response->getHeaders() as $h) { header($h); } http_response_code($response->getStatus()); $e = $response->getEntity(); if (!is_null($e)) { $this->renderEntity($e); } }