class CommandCache implements SimpleCacheInterface (View source)

Command cache implementation.

This wrapper implements a cache usable with the annotated-command library's command cache. It uses a Drush JSONCache for its back-end.

Properties

protected $cacheBackend

Methods

__construct(CacheInterface $cacheBackend)

No description

boolean
has(string $key)

Test for an entry from the cache

array
get(string $key)

Get an entry from the cache

set(string $key, array $data)

Store an entry in the cache

valid($cacheItem)

No description

Details

__construct(CacheInterface $cacheBackend)

Parameters

CacheInterface $cacheBackend

boolean has(string $key)

Test for an entry from the cache

Parameters

string $key

Return Value

boolean

array get(string $key)

Get an entry from the cache

Parameters

string $key

Return Value

array

set(string $key, array $data)

Store an entry in the cache

Parameters

string $key
array $data

protected valid($cacheItem)

Parameters

$cacheItem