A wrapper to multiple cache for workload distribution using CachePeer childs. More...
Public Member Functions | |
addPeer ($label, CachePeer $peer, $level=self::LEVEL_NORMAL) | |
dropPeer ($label) | |
setClassLevel ($class, $level) | |
checkAlive () | |
increment ($key, $value) | |
low-level cache access | |
decrement ($key, $value) | |
get ($key) | |
getList ($indexes) | |
delete ($key) | |
clean () | |
getStats () | |
append ($key, $data) | |
Static Public Member Functions | |
static | create () |
Public Attributes | |
const | LEVEL_ULTRAHIGH = 0xFFFF |
const | LEVEL_HIGH = 0xC000 |
const | LEVEL_NORMAL = 0x8000 |
const | LEVEL_LOW = 0x4000 |
const | LEVEL_VERYLOW = 0x0001 |
Protected Member Functions | |
store ($action, $key, $value, $expires=Cache::EXPIRES_MINIMUM) | |
guessLabel ($key) | |
brain | |
Protected Attributes | |
$peers = array() | |
Private Attributes | |
$levels = array() |
A wrapper to multiple cache for workload distribution using CachePeer childs.
Definition at line 18 of file AggregateCache.class.php.
AggregateCache::addPeer | ( | $ | label, | |
CachePeer $ | peer, | |||
$ | level = self::LEVEL_NORMAL | |||
) |
Reimplemented in SimpleAggregateCache.
Definition at line 40 of file AggregateCache.class.php.
References CachePeer::isAlive().
AggregateCache::append | ( | $ | key, | |
$ | data | |||
) |
Reimplemented from CachePeer.
Definition at line 190 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::checkAlive | ( | ) |
Reimplemented in SimpleAggregateCache.
Definition at line 84 of file AggregateCache.class.php.
References CachePeer::isAlive().
Referenced by append(), clean(), decrement(), delete(), get(), getList(), increment(), and store().
AggregateCache::clean | ( | ) |
Reimplemented from CachePeer.
Definition at line 170 of file AggregateCache.class.php.
References checkAlive().
static AggregateCache::create | ( | ) | [static] |
Reimplemented in SimpleAggregateCache.
Definition at line 32 of file AggregateCache.class.php.
AggregateCache::decrement | ( | $ | key, | |
$ | value | |||
) |
Reimplemented from CachePeer.
Definition at line 113 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::delete | ( | $ | key | ) |
Reimplemented from CachePeer.
Definition at line 155 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::dropPeer | ( | $ | label | ) |
Reimplemented in SimpleAggregateCache.
Definition at line 62 of file AggregateCache.class.php.
AggregateCache::get | ( | $ | key | ) |
Reimplemented from CachePeer.
Definition at line 125 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::getList | ( | $ | indexes | ) |
Reimplemented from CachePeer.
Definition at line 137 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::getStats | ( | ) |
Definition at line 180 of file AggregateCache.class.php.
AggregateCache::guessLabel | ( | $ | key | ) | [protected] |
brain
Reimplemented in SimpleAggregateCache.
Definition at line 224 of file AggregateCache.class.php.
References SelectivePeer::getClassName().
Referenced by append(), decrement(), delete(), get(), getList(), increment(), and store().
AggregateCache::increment | ( | $ | key, | |
$ | value | |||
) |
low-level cache access
Reimplemented from CachePeer.
Definition at line 101 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::setClassLevel | ( | $ | class, | |
$ | level | |||
) |
Definition at line 77 of file AggregateCache.class.php.
AggregateCache::store | ( | $ | action, | |
$ | key, | |||
$ | value, | |||
$ | expires = Cache::EXPIRES_MINIMUM | |||
) | [protected] |
Reimplemented from CachePeer.
Definition at line 202 of file AggregateCache.class.php.
References checkAlive(), guessLabel(), and CachePeer::isAlive().
AggregateCache::$levels = array() [private] |
Definition at line 27 of file AggregateCache.class.php.
AggregateCache::$peers = array() [protected] |
Definition at line 26 of file AggregateCache.class.php.
const AggregateCache::LEVEL_HIGH = 0xC000 |
Definition at line 21 of file AggregateCache.class.php.
const AggregateCache::LEVEL_LOW = 0x4000 |
Definition at line 23 of file AggregateCache.class.php.
const AggregateCache::LEVEL_NORMAL = 0x8000 |
Definition at line 22 of file AggregateCache.class.php.
const AggregateCache::LEVEL_ULTRAHIGH = 0xFFFF |
Definition at line 20 of file AggregateCache.class.php.
const AggregateCache::LEVEL_VERYLOW = 0x0001 |
Definition at line 24 of file AggregateCache.class.php.