Skip to content

Latest commit

 

History

History
27 lines (16 loc) · 533 Bytes

class-session-cache-engine.md

File metadata and controls

27 lines (16 loc) · 533 Bytes

Class SessionCacheEngine

This class uses the PHP Session as the cache engine. This will persist the cache between requests while the user session is active.

The cache is not shared between different users.

PSR-16 Constructor

$cache = new \ByJG\Cache\Psr16\SessionCacheEngine($prefix)

PSR-6 Constructor

$cachePool = \ByJG\Cache\Factory::createSessionPool($prefix, $bufferSize = 10)

or

$cachePool = new \ByJG\Cache\Psr6\CachePool(new \ByJG\Cache\Psr16\SessionCacheEngine($prefix));