function Response::setPrivate
Marks the response as "private".
It makes the response ineligible for serving other clients.
@final
Return value
$this
2 calls to Response::setPrivate()
- BigPipeResponse::populateBasedOnOriginalHtmlResponse in core/
modules/ big_pipe/ src/ Render/ BigPipeResponse.php - Populates this BigPipeResponse object based on the original HTML response.
- Response::setCache in vendor/
symfony/ http-foundation/ Response.php - Sets the response's cache headers (validation and/or expiration).
File
-
vendor/
symfony/ http-foundation/ Response.php, line 585
Class
- Response
- Response represents an HTTP response.
Namespace
Symfony\Component\HttpFoundationCode
public function setPrivate() : static {
$this->headers
->removeCacheControlDirective('public');
$this->headers
->addCacheControlDirective('private');
return $this;
}