Definition at line 37 of file ZendServer.php.
◆ _clear()
◆ _fetch()
Fetch data
- Parameters
-
- Exceptions
-
◆ _store()
_store |
( |
|
$data, |
|
|
|
$id, |
|
|
|
$timeToLive |
|
) |
| |
|
abstractprotected |
Store data
- Parameters
-
mixed | $data | Object to store |
string | $id | Cache id |
int | $timeToLive | Time to live in seconds |
- Exceptions
-
◆ _unset()
◆ clean()
Clean some cache records
Available modes are : 'all' (default) => remove all cache entries ($tags is not used) 'old' => unsupported 'matchingTag' => unsupported 'notMatchingTag' => unsupported 'matchingAnyTag' => unsupported
- Parameters
-
string | $mode | clean mode |
array | $tags | array of tags |
- Exceptions
-
- Returns
- boolean true if no problem
Implements Zend_Cache_Backend_Interface.
Definition at line 186 of file ZendServer.php.
194 $this->
_log(
"Zend_Cache_Backend_ZendServer::clean() : CLEANING_MODE_OLD is unsupported by the Zend Server backends.");
200 $this->
_log(
'Zend_Cache_Backend_ZendServer::clean() : tags are unsupported by the Zend Server backends.');
_log($message, $priority=4)
const CLEANING_MODE_NOT_MATCHING_TAG
if($exist=($block->getProductCollection() && $block->getProductCollection() ->getSize())) $mode
static throwException($msg, Exception $e=null)
const CLEANING_MODE_MATCHING_ANY_TAG
const CLEANING_MODE_MATCHING_TAG
◆ load()
load |
( |
|
$id, |
|
|
|
$doNotTestCacheValidity = false |
|
) |
| |
Test if a cache is available for the given id and (if yes) return it (false else)
- Parameters
-
string | $id | cache id |
boolean | $doNotTestCacheValidity | if set to true, the cache validity won't be tested |
- Returns
- string cached datas (or false)
Implements Zend_Cache_Backend_Interface.
Definition at line 88 of file ZendServer.php.
◆ remove()
◆ save()
save |
( |
|
$data, |
|
|
|
$id, |
|
|
|
$tags = array() , |
|
|
|
$specificLifetime = false |
|
) |
| |
Save some string datas into a cache record
Note : $data is always "string" (serialization is done by the core not by the backend)
- Parameters
-
string | $data | datas to cache |
string | $id | cache id |
array | $tags | array of strings, the cache record will be tagged by each string entry |
int | $specificLifetime | if != false, set a specific lifetime for this cache record (null => infinite lifetime) |
- Returns
- boolean true if no problem
Implements Zend_Cache_Backend_Interface.
Definition at line 141 of file ZendServer.php.
146 'expire' => $this->_expireTime($lifetime),
149 if (count($tags) > 0) {
150 $this->
_log(
'Zend_Cache_Backend_ZendServer::save() : tags are unsupported by the ZendServer backends');
154 $this->
_store($metadatas,
'internal-metadatas---' .
$id, $lifetime);
_log($message, $priority=4)
_store($data, $id, $timeToLive)
getLifetime($specificLifetime)
◆ test()
Test if a cache is available or not (for the given id)
- Parameters
-
- Returns
- mixed false (a cache is not available) or "last modified" timestamp (int) of the available cache record
- Exceptions
-
Implements Zend_Cache_Backend_Interface.
Definition at line 104 of file ZendServer.php.
106 $tmp = $this->
_fetch(
'internal-metadatas---' .
$id);
107 if ($tmp !==
false) {
108 if (!is_array($tmp) || !isset($tmp[
'mtime'])) {
111 return $tmp['mtime
'];
static throwException($msg, Exception $e=null)
◆ $_options
Initial value:= array(
'namespace' => 'zendframework'
)
Definition at line 47 of file ZendServer.php.
The documentation for this class was generated from the following file:
- vendor/magento/zendframework1/library/Zend/Cache/Backend/ZendServer.php