\Pivot\Core\Middleware\HttpCache

Service Aware Cache Note, for public routes we do not care about any of this and dont need to load all these dependencies, thus the cache manager is set in several places.

Summary

Methods
Properties
Constants
parseBearerToken()
__construct()
__invoke()
No public properties found
No constants found
getServiceLocator()
No protected properties found
N/A
lookForToken()
$serviceLocator
$cacheManager
N/A

Properties

$serviceLocator

$serviceLocator : \Pivot\Core\Middleware\Pivot\Core\Services\ServliceLocator

Service locator

Type

\Pivot\Core\Middleware\Pivot\Core\Services\ServliceLocator

$cacheManager

$cacheManager : \Pivot\Core\Middleware\Http\Pivot\Core\Cache\CacheManager

CacheManager

Type

\Pivot\Core\Middleware\Http\Pivot\Core\Cache\CacheManager

Methods

parseBearerToken()

parseBearerToken(  $token) 

Parameters

$token

__construct()

__construct(object  $serviceLocator) 

inject the service locator

Parameters

object $serviceLocator

__invoke()

__invoke(\Psr\Http\Message\ServerRequestInterface  $request, \Psr\Http\Message\ResponseInterface  $response, callable  $next) : \Psr\Http\Message\ResponseInterface

Starts the session

Parameters

\Psr\Http\Message\ServerRequestInterface $request

PSR7 request

\Psr\Http\Message\ResponseInterface $response

PSR7 response

callable $next

Next middleware

Returns

\Psr\Http\Message\ResponseInterface

getServiceLocator()

getServiceLocator() : \Pivot\Core\Middleware\ServiceLocator

gets the service locator

Returns

\Pivot\Core\Middleware\ServiceLocator

lookForToken()

lookForToken(  $request) 

Parameters

$request