Class TCacheDependency
TCacheDependency class.
TCacheDependency is the base class implementing ICacheDependency
interface. Descendant classes must implement ICacheDependency::getHasChanged()
to provide
actual dependency checking logic.
The property value of getHasChanged HasChanged tells whether the dependency is changed or not.
You may disable the dependency checking by setting setEnabled Enabled to false.
Note, since the dependency objects often need to be serialized so that they can persist across requests, you may need to implement __sleep() and __wakeup() if the dependency objects contain resource handles which are not serializable.
Currently, the following dependency classes are provided in the PRADO release:
TFileCacheDependency
: checks whether a file is changed or notTDirectoryCacheDependency
: checks whether a directory is changed or notTGlobalStateCacheDependency
: checks whether a global state is changed or notTChainedCacheDependency
: checks whether any of a list of dependencies is changed or not
- TComponent
-
TCacheDependency implements ICacheDependency
Direct known subclasses
TApplicationStateCacheDependency, TChainedCacheDependency, TDirectoryCacheDependency, TFileCacheDependency, TGlobalStateCacheDependency
Abstract
Package: System\Caching
Copyright: Copyright © 2005-2014 PradoSoft
License: http://www.pradosoft.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 3.1.0
Located at Caching/TCache.php
Package: System\Caching
Copyright: Copyright © 2005-2014 PradoSoft
License: http://www.pradosoft.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 3.1.0
Located at Caching/TCache.php
getHasChanged()
|
GLOBAL_RAISE_EVENT_LISTENER
|