📚 Looking for current Exponential documentation? This site contains legacy SDK & API reference docs (eZ Publish era). For up-to-date 2026 product documentation, visit doc.exponential.earth.

  class / eZTemplateTreeCache  

eZTemplateTreeCache Class Reference

Cache handling for template tree nodes. More...

List of all members.


Public Methods

 setCachedTree ($originalKey,$uri,$res,$templatePath,&$extraParameters,&$root)

Static Public Methods

& cacheTable ()
& cachedTree ($key,$uri,$res,$templatePath,&$extraParameters)
 isCacheEnabled ()
 cacheDirectory ()
 canRestoreCache ($key,$timestamp)
 restoreCache ($key)
 storeCache ($key)

Static Private Methods

 internalKey ($key)

Detailed Description

Cache handling for template tree nodes.

Definition at line eztemplatetreecache.php.


Member Function Documentation

eZTemplateTreeCache::cacheDirectory (    )  [static]
 

Returns:
the cache directory for tree node cache files.

Definition at line eztemplatetreecache.php.

References eZDir::path().

Referenced by storeCache().

& eZTemplateTreeCache::cachedTree (  $    key,
$    uri,
$    res,
$    templatePath,
&$    extraParameters
)  [static]
 

Returns:
the cache node tree which is stored with the cache key $key. Returns null if no cache data was found.

Definition at line eztemplatetreecache.php.

References eZDebugSetting::writeDebug().

Referenced by eZTemplateFileResource::hasCachedProcessTree().

& eZTemplateTreeCache::cacheTable (    )  [static]
 

Returns:
the cache table which has cache keys and cache data.

Definition at line eztemplatetreecache.php.

Referenced by storeCache().

eZTemplateTreeCache::canRestoreCache (  $    key,
$    timestamp
)  [static]
 

Returns:
true if the cache with the key $key can be restored. A cache file is found restorable when it exists and has a timestamp higher or equal to $timestamp.

Definition at line eztemplatetreecache.php.

References isCacheEnabled().

Referenced by eZTemplateFileResource::hasCachedProcessTree().

eZTemplateTreeCache::internalKey (  $    key )  [static, private]
 

Returns:
a new key from $key which has some additional info.

Definition at line eztemplatetreecache.php.

References eZINI::instance().

Referenced by storeCache().

eZTemplateTreeCache::isCacheEnabled (    )  [static]
 

Returns:
true if template tree node caching is enabled.
Note:
To change this setting edit settings/site.ini and locate the group TemplateSettings and the entry NodeTreeCaching.

Definition at line eztemplatetreecache.php.

References eZINI::instance().

Referenced by storeCache().

eZTemplateTreeCache::restoreCache (  $    key )  [static]
 

Loads the cache with the key $key from a file and sets the result in the cache table.

Returns:
true if the cache was successfully restored.

Definition at line eztemplatetreecache.php.

References eZDebug::writeWarning().

Referenced by restoreCache().

eZTemplateTreeCache::setCachedTree (  $    originalKey,
$    uri,
$    res,
$    templatePath,
&$    extraParameters,
&$    root
) 
 

Sets the template tree node $root to be cached with the cache key $root.

Note:
Trying to overwrite and existing cache key will give a warning and fail.

Definition at line eztemplatetreecache.php.

References eZDebug::writeWarning().

Referenced by setCachedTree().

eZTemplateTreeCache::storeCache (  $    key )  [static]
 

Stores the data of the cache with the key $key to a file.

Returns:
false if the cache does not exist.

Definition at line eztemplatetreecache.php.

References eZDebug::writeWarning().

Referenced by storeCache().


The documentation for this class was generated from the following file:  

Exponential Copyright © 1998 - 2026 7x