eZTemplateFileResource Class ReferenceHandles filesystem retrieval of templates.
More...
List of all members.
|
Public Methods |
| eZTemplateFileResource ($name="file",$servesStaticData=true) |
| resourceName () |
| cacheKey ($keyData,$res,$templatePath,&$extraParameters) |
| hasCachedProcessTree ($keyData,$uri,$res,$templatePath,&$extraParameters,$timestamp) |
| generateProcessCache ($keyData,$uri,$res,$templatePath,&$extraParameters,&$resourceData) |
& | cachedTemplateTree ($keyData,$uri,$res,$templatePath,&$extraParameters,$timestamp) |
| setCachedTemplateTree ($keyData,$uri,$res,$templatePath,&$extraParameters,&$root) |
| handleResource (&$tpl,&$resourceData,$method,&$extraParameters) |
Static Public Methods |
| handleResourceData (&$tpl,&$handler,&$resourceData,$method,&$extraParameters) |
Private Attributes |
| Name |
| ServesStaticData |
| True if the data served from this resource is static, ie it can be cached properly.
|
| TemplateCache |
| The cache for templates.
|
Detailed Description
Handles filesystem retrieval of templates.
Templates are loaded from the disk and returned to the template system. The name of the resource is "file:".
Definition at line eztemplatefileresource.php.
Constructor & Destructor Documentation
eZTemplateFileResource::eZTemplateFileResource |
( |
$ |
name = "file", |
|
|
$ |
servesStaticData = true |
|
) |
|
|
|
Initializes with a default resource name "file". Also sets whether the resource servers static data files, this is needed for the cache system.
Definition at line eztemplatefileresource.php.
References TemplateCache. |
Member Function Documentation
& eZTemplateFileResource::cachedTemplateTree |
( |
$ |
keyData, |
|
|
$ |
uri, |
|
|
$ |
res, |
|
|
$ |
templatePath, |
|
|
&$ |
extraParameters, |
|
|
$ |
timestamp |
|
) |
|
|
eZTemplateFileResource::cacheKey |
( |
$ |
keyData, |
|
|
$ |
res, |
|
|
$ |
templatePath, |
|
|
&$ |
extraParameters |
|
) |
|
|
|
Generates a unique key string from the input data and returns it. The key will be used for storing cached data and retrieving cache files. When implementing file resource handlers this key must be reimplemented if the current code does not generate correct keys. However most file based resource handlers can simple reuse this class.
Default implementation returns an md5 of the $keyData.
Definition at line eztemplatefileresource.php.
Referenced by setCachedTemplateTree(). |
eZTemplateFileResource::generateProcessCache |
( |
$ |
keyData, |
|
|
$ |
uri, |
|
|
$ |
res, |
|
|
$ |
templatePath, |
|
|
&$ |
extraParameters, |
|
|
&$ |
resourceData |
|
) |
|
|
eZTemplateFileResource::handleResource |
( |
&$ |
tpl, |
|
|
&$ |
resourceData, |
|
|
$ |
method, |
|
|
&$ |
extraParameters |
|
) |
|
|
eZTemplateFileResource::handleResourceData |
( |
&$ |
tpl, |
|
|
&$ |
handler, |
|
|
&$ |
resourceData, |
|
|
$ |
method, |
|
|
&$ |
extraParameters |
|
) |
[static] |
|
|
Reusable function for handling file based loading. Call this with the resource handler object in $handler. It will load the template file and handle any charsets conversion if necessary. It will also handle tree node caching if one is found.
Definition at line eztemplatefileresource.php.
References eZDebug::writeNotice().
Referenced by handleResource(). |
eZTemplateFileResource::hasCachedProcessTree |
( |
$ |
keyData, |
|
|
$ |
uri, |
|
|
$ |
res, |
|
|
$ |
templatePath, |
|
|
&$ |
extraParameters, |
|
|
$ |
timestamp |
|
) |
|
|
eZTemplateFileResource::resourceName |
( |
|
) |
|
|
eZTemplateFileResource::setCachedTemplateTree |
( |
$ |
keyData, |
|
|
$ |
uri, |
|
|
$ |
res, |
|
|
$ |
templatePath, |
|
|
&$ |
extraParameters, |
|
|
&$ |
root |
|
) |
|
|
Member Data Documentation
eZTemplateFileResource::Name [private]
|
|
The documentation for this class was generated from the following file:
|