Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
__construct (array $options=[]) | |
load ($id, $doNotTestCacheValidity=false) | |
test ($id) | |
save ($data, $id, $tags=[], $specificLifetime=false) | |
remove ($id) | |
clean ($mode=\Zend_Cache::CLEANING_MODE_ALL, $tags=[]) | |
getFillingPercentage () | |
getTags () | |
getIdsMatchingTags ($tags=[]) | |
getIdsNotMatchingTags ($tags=[]) | |
getIdsMatchingAnyTags ($tags=[]) | |
getIds () | |
getMetadatas ($id) | |
touch ($id, $extraLifetime) | |
getCapabilities () | |
![]() | |
__construct (array $options=array()) | |
setDirectives ($directives) | |
setOption ($name, $value) | |
getOption ($name) | |
getLifetime ($specificLifetime) | |
isAutomaticCleaningAvailable () | |
getTmpDir () | |
![]() | |
setDirectives ($directives) | |
Data Fields | |
const | TAGS_UNSUPPORTED_BY_CLEAN_OF_EACCELERATOR_BACKEND |
const | TAGS_UNSUPPORTED_BY_SAVE_OF_EACCELERATOR_BACKEND |
Additional Inherited Members | |
![]() | |
_isGoodTmpDir ($dir) | |
_loggerSanity () | |
_log ($message, $priority=4) | |
![]() | |
$_directives | |
$_options = array() | |
Definition at line 9 of file Eaccelerator.php.
__construct | ( | array | $options = [] | ) |
Constructor
array | $options | associative array of options |
Definition at line 26 of file Eaccelerator.php.
clean | ( | $mode = \Zend_Cache::CLEANING_MODE_ALL , |
|
$tags = [] |
|||
) |
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
string | $mode | clean mode |
string[] | $tags array of tags |
Implements Zend_Cache_Backend_Interface.
Definition at line 117 of file Eaccelerator.php.
getCapabilities | ( | ) |
Return an associative array of capabilities (booleans) of the backend
The array must include these keys :
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 305 of file Eaccelerator.php.
getFillingPercentage | ( | ) |
Return the filling percentage of the backend storage
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 146 of file Eaccelerator.php.
getIds | ( | ) |
Return an array of stored cache ids
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 223 of file Eaccelerator.php.
getIdsMatchingAnyTags | ( | $tags = [] | ) |
Return an array of stored cache ids which match any given tags
In case of multiple tags, a logical AND is made between tags
string[] | $tags array of tags |
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 211 of file Eaccelerator.php.
getIdsMatchingTags | ( | $tags = [] | ) |
Return an array of stored cache ids which match given tags
In case of multiple tags, a logical AND is made between tags
array | $tags | array of tags |
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 181 of file Eaccelerator.php.
getIdsNotMatchingTags | ( | $tags = [] | ) |
Return an array of stored cache ids which don't match given tags
In case of multiple tags, a logical OR is made between tags
string[] | $tags array of tags |
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 196 of file Eaccelerator.php.
getMetadatas | ( | $id | ) |
Return an array of metadatas for the given cache id
The array must include these keys :
string | $id | cache id |
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 245 of file Eaccelerator.php.
getTags | ( | ) |
Return an array of stored tags
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 166 of file Eaccelerator.php.
load | ( | $id, | |
$doNotTestCacheValidity = false |
|||
) |
Test if a cache is available for the given id and (if yes) return it (false else)
WARNING $doNotTestCacheValidity=true is unsupported by the Eaccelerator backend
string | $id | cache id |
boolean | $doNotTestCacheValidity | if set to true, the cache validity won't be tested |
Implements Zend_Cache_Backend_Interface.
Definition at line 44 of file Eaccelerator.php.
remove | ( | $id | ) |
Remove a cache record
string | $id | cache id |
Implements Zend_Cache_Backend_Interface.
Definition at line 96 of file Eaccelerator.php.
save | ( | $data, | |
$id, | |||
$tags = [] , |
|||
$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)
string | $data | datas to cache |
string | $id | cache id |
string[] | $tags array of strings, the cache record will be tagged by each string entry | |
int | bool | $specificLifetime | Integer to set a specific lifetime or null for infinite lifetime |
Implements Zend_Cache_Backend_Interface.
Definition at line 80 of file Eaccelerator.php.
test | ( | $id | ) |
Test if a cache is available or not (for the given id)
string | $id | cache id |
Implements Zend_Cache_Backend_Interface.
Definition at line 59 of file Eaccelerator.php.
touch | ( | $id, | |
$extraLifetime | |||
) |
Give (if possible) an extra lifetime to the given cache id
string | $id | cache id |
int | $extraLifetime |
Implements Zend_Cache_Backend_ExtendedInterface.
Definition at line 269 of file Eaccelerator.php.
const TAGS_UNSUPPORTED_BY_CLEAN_OF_EACCELERATOR_BACKEND |
Log message
Definition at line 14 of file Eaccelerator.php.
const TAGS_UNSUPPORTED_BY_SAVE_OF_EACCELERATOR_BACKEND |
Definition at line 17 of file Eaccelerator.php.