PHP Class Cache\Adapter\MongoDB\MongoDBCachePool

Author: Tobias Nyholm ([email protected])
Inheritance: extends Cache\Adapter\Common\AbstractCachePool
Datei anzeigen Open project: php-cache/cache Class Usage Examples

Public Methods

Method Description
__construct ( MongoDB\Collection $collection )
createCollection ( MongoDB\Driver\Manager $manager, string $database, string $collection ) : MongoDB\Collection

Protected Methods

Method Description
clearAllObjectsFromCache ( )
clearOneObjectFromCache ( $key )
fetchObjectFromCache ( $key )
storeItemInCache ( Psr\Cache\CacheItemInterface $item, $ttl )

Method Details

__construct() public method

public __construct ( MongoDB\Collection $collection )
$collection MongoDB\Collection

clearAllObjectsFromCache() protected method

protected clearAllObjectsFromCache ( )

clearOneObjectFromCache() protected method

protected clearOneObjectFromCache ( $key )

createCollection() public static method

public static createCollection ( MongoDB\Driver\Manager $manager, string $database, string $collection ) : MongoDB\Collection
$manager MongoDB\Driver\Manager
$database string
$collection string
return MongoDB\Collection

fetchObjectFromCache() protected method

protected fetchObjectFromCache ( $key )

storeItemInCache() protected method

protected storeItemInCache ( Psr\Cache\CacheItemInterface $item, $ttl )
$item Psr\Cache\CacheItemInterface