APC cache implementation
copyright | Copyright (c) 2012, Open Source Solutions Limited, Dublin, Ireland |
---|---|
author | Barry O'Donovan |
__construct(int $ttl= 300
, string $prefix= 'OSS_SNMP_'
) : \OSS_SNMP\Cache\Basic
int
Set the default ttl
string
Set the default prefix for caching variable names
\OSS_SNMP\Cache\Basic
An instance of the cache ($this) for fluent interfacesclear(string $var)
string
The name of the value to clear
clearAll()
load(string $var) : mixed | null
string
The name of the value to load
mixed
null
The value from the cache or nullsave(string $var, mixed $val, int $ttl = null
) : mixed
string
The name of the value to save
mixed
The value to save
int
The time to live of the variable if you want to override the default
mixed
The value (as passed)clear($varName)
clearAll()
load($varName)
save($varName, $varValue)
$_prefix : string
'OSS_SNMP_'
$_ttl : int
300