12
* API for all cache engine adapters.
16
interface HippoCacheEngine {
18
* All subclasses must implement a get() method to return
21
* @return mixed FALSE if not in cache, otherwise the cached item
22
* @param key Key to the cache item
23
* @param options Options to pass to the cache engine (see engine specifics)
25
public function get($key, $options= array());
28
* All subclasses must implement a set() method to
29
* write the cache item to the cache
31
* @return bool Did the write succeed?
32
* @param key The key for the cache item
33
* @param value The value of the cache item
35
public function set($key, $value);
38
* All subclasses must implement a delete() method to
39
* remove a cache item from the cache
41
* @return bool Did the delete succeed?
42
* @param key The key for the cache item
44
public function delete($key);
47
* All subclasses must implement a purge() method to
48
* remove blocks of cache items from the cache
50
* optional options argument can contain subclass-specific
51
* arguments for the purge.
53
* @return bool Did the purge succeed?
54
* @param options Options to pass the subclass-specific interface
56
public function purge($options=array());
60
12
* Factory class for easy generation of cache engines