ILIAS
release_5-4 Revision v5.4.26-12-gabc799a52e6
|
Loads a template from a string. More...
Public Member Functions | |
getSource ($name) | |
Gets the source code of a template, given its name. More... | |
getSourceContext ($name) | |
Returns the source context for a given template logical name. More... | |
exists ($name) | |
Check if we have the source code of a template, given its name. More... | |
getCacheKey ($name) | |
Gets the cache key to use for the cache for a given template name. More... | |
isFresh ($name, $time) | |
Returns true if the template is still fresh. More... | |
Loads a template from a string.
This loader should NEVER be used. It only exists for Twig internal purposes.
When using this loader with a cache mechanism, you should know that a new cache key is generated each time a template content "changes" (the cache key being the source code of the template). If you don't want to see your cache grows out of control, you need to take care of clearing the old cache file by yourself.
Definition at line 30 of file String.php.
Twig_Loader_String::exists | ( | $name | ) |
Check if we have the source code of a template, given its name.
string | $name | The name of the template to check if we can load |
Implements Twig_ExistsLoaderInterface.
Definition at line 44 of file String.php.
Twig_Loader_String::getCacheKey | ( | $name | ) |
Gets the cache key to use for the cache for a given template name.
string | $name | The name of the template to load |
Twig_Error_Loader | When $name is not found |
Implements Twig_LoaderInterface.
Definition at line 49 of file String.php.
References $name.
Twig_Loader_String::getSource | ( | $name | ) |
Gets the source code of a template, given its name.
string | $name | The name of the template to load |
Twig_Error_Loader | When $name is not found |
Implements Twig_LoaderInterface.
Definition at line 32 of file String.php.
References $name.
Twig_Loader_String::getSourceContext | ( | $name | ) |
Returns the source context for a given template logical name.
string | $name | The template logical name |
Twig_Error_Loader | When $name is not found |
Implements Twig_SourceContextLoaderInterface.
Definition at line 39 of file String.php.
References $name.
Twig_Loader_String::isFresh | ( | $name, | |
$time | |||
) |
Returns true if the template is still fresh.
string | $name | The template name |
int | $time | Timestamp of the last modification time of the cached template |
Twig_Error_Loader | When $name is not found |
Implements Twig_LoaderInterface.
Definition at line 54 of file String.php.