## Class TCacheDependency

Description

Implements interfaces:

- ICacheDependency

TCacheDependency class.

TCacheDependency is the base class implementing ICacheDependency interface. Descendant classes must implement getHasChanged() to provide actual dependency checking logic.

The property value of getHasChanged tells whether the dependency is changed or not.

You may disable the dependency checking by setting setEnabled 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 not
- TDirectoryCacheDependency: checks whether a directory is changed or not
- TGlobalStateCacheDependency: checks whether a global state is changed or not
- TChainedCacheDependency: checks whether any of a list of dependencies is changed or not

- abstract:
- since: 3.1.0
- version: $Id: TCache.php 2362 2008-01-10 04:59:06Z xue $
- author: Qiang Xue <qiang.xue@gmail.com>

Located in /Caching/TCache.php (line 313)

    TComponent
       |
       --TCacheDependency

Direct descendents

Class | Description
--- | ---
TFileCacheDependency | TFileCacheDependency class.
TDirectoryCacheDependency | TDirectoryCacheDependency class.
TGlobalStateCacheDependency | TGlobalStateCacheDependency class.
TChainedCacheDependency | TChainedCacheDependency class.
TApplicationStateCacheDependency | TApplicationStateCacheDependency class.

Methods

#### Inherited Methods

Inherited From TComponent

> TComponent::addParsedObject()
> TComponent::attachEventHandler()
> TComponent::canGetProperty()
> TComponent::canSetProperty()
> TComponent::createdOnTemplate()
> TComponent::detachEventHandler()
> TComponent::evaluateExpression()
> TComponent::evaluateStatements()
> TComponent::getEventHandlers()
> TComponent::getSubProperty()
> TComponent::hasEvent()
> TComponent::hasEventHandler()
> TComponent::hasProperty()
> TComponent::raiseEvent()
> TComponent::setSubProperty()
> TComponent::__get()
> TComponent::__set()

Documentation generated on Mon, 21 Apr 2008 11:32:03 -0400 by phpDocumentor 1.3.0RC4