Skip to content

ContentCacheMiddleware

Properties

cacheItemPool

protected \Psr\Cache\CacheItemPoolInterface $cacheItemPool

Methods

__construct

public __construct(\Psr\Cache\CacheItemPoolInterface $cacheItemPool): mixed

Parameters:

Parameter Type Description
$cacheItemPool \Psr\Cache\CacheItemPoolInterface

process

public process(\Psr\Http\Message\ServerRequestInterface $request, \Psr\Http\Server\RequestHandlerInterface $handler): \Psr\Http\Message\ResponseInterface

Parameters:

Parameter Type Description
$request \Psr\Http\Message\ServerRequestInterface
$handler \Psr\Http\Server\RequestHandlerInterface

Throws:


buildResponse

protected buildResponse(mixed $html, \Psr\Http\Message\ResponseInterface $response): \Psr\Http\Message\ResponseInterface

Parameters:

Parameter Type Description
$html mixed
$response \Psr\Http\Message\ResponseInterface

createKeyFromRequest

protected createKeyFromRequest(\Psr\Http\Message\RequestInterface $request): string

Parameters:

Parameter Type Description
$request \Psr\Http\Message\RequestInterface

getCachedResponseHtml

protected getCachedResponseHtml(\Psr\Http\Message\RequestInterface $request): mixed

Parameters:

Parameter Type Description
$request \Psr\Http\Message\RequestInterface

Throws:


cacheResponse

protected cacheResponse(\Psr\Http\Message\RequestInterface $request, \Psr\Http\Message\ResponseInterface $response): void

Parameters:

Parameter Type Description
$request \Psr\Http\Message\RequestInterface
$response \Psr\Http\Message\ResponseInterface


Automatically generated on 2025-10-13