Chain
Less than 1 minute
Chain
The cache backend chaining backend.
This backend allows other caching backends to be chained together for fault tollerance. All operations (has,get,set,remove) are performed on ALL backends at once.
Configuration options for this backend is an array of 'backend_name' => 'backend_options' pairs. (see each backend for available options)
For example:
[ 'file' => [ 'cache_dir' => '/tmp/cache' ], 'memcached' => [ 'server' => 'localhost' ] ]
Properties
backends
private array $backendsorder
private array $orderMethods
available
public available(): boolinit
public init(string $namespace): voidParameters
| Parameter | Type | Description |
|---|---|---|
$namespace | string |
has
public has(string $key, bool $checkEmpty): boolParameters
| Parameter | Type | Description |
|---|---|---|
$key | string | |
$checkEmpty | bool |
get
public get(string $key): mixedParameters
| Parameter | Type | Description |
|---|---|---|
$key | string |
set
public set(string $key, mixed $value, int $timeout): boolParameters
| Parameter | Type | Description |
|---|---|---|
$key | string | |
$value | mixed | |
$timeout | int |
remove
public remove(string $key): boolParameters
| Parameter | Type | Description |
|---|---|---|
$key | string |
clear
public clear(): boolsetExpireTimeout
public setExpireTimeout(int $timeout): voidParameters
| Parameter | Type | Description |
|---|---|---|
$timeout | int |
toArray
public toArray(): voidcount
public count(): intGenerated by Hazaar API Doc Generator on Mon, 27 Oct 2025 13:01:29 +0000