ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
|
Interface implemented by cache classes. More...
Public Member Functions | |
generateKey ($name, $className) | |
Generates a cache key for the given template class name. More... | |
write ($key, $content) | |
Writes the compiled template to cache. More... | |
load ($key) | |
Loads a template from the cache. More... | |
getTimestamp ($key) | |
Returns the modification timestamp of a key. More... | |
Interface implemented by cache classes.
It is highly recommended to always store templates on the filesystem to benefit from the PHP opcode cache. This interface is mostly useful if you need to implement a custom strategy for storing templates on the filesystem.
Definition at line 21 of file CacheInterface.php.
Twig_CacheInterface::generateKey | ( | $name, | |
$className | |||
) |
Generates a cache key for the given template class name.
string | $name | The template name |
string | $className | The template class name |
Implemented in Twig_Cache_Filesystem, and Twig_Cache_Null.
Twig_CacheInterface::getTimestamp | ( | $key | ) |
Returns the modification timestamp of a key.
string | $key | The cache key |
Implemented in Twig_Cache_Filesystem, and Twig_Cache_Null.
Twig_CacheInterface::load | ( | $key | ) |
Loads a template from the cache.
string | $key | The cache key |
Implemented in Twig_Cache_Filesystem, and Twig_Cache_Null.
Twig_CacheInterface::write | ( | $key, | |
$content | |||
) |
Writes the compiled template to cache.
string | $key | The cache key |
string | $content | The template representation as a PHP class |
Implemented in Twig_Cache_Filesystem, and Twig_Cache_Null.