private function determineCacheability()
{
if (!$this->_cacheChecked) {
$this->_cacheChecked = true;
if ($this->_duration > 0 && ($this->_cachePostBack || !$this->getPage()->getIsPostBack())) {
if ($this->_cacheModuleID !== '') {
$this->_cache = $this->getApplication()->getModule($this->_cacheModuleID);
if (!$this->_cache instanceof ICache) {
throw new TConfigurationException('outputcache_cachemoduleid_invalid', $this->_cacheModuleID);
}
} else {
$this->_cache = $this->getApplication()->getCache();
}
if ($this->_cache !== null) {
$this->_cacheAvailable = true;
$data = $this->_cache->get($this->getCacheKey());
if (is_array($data)) {
$param = new TOutputCacheCheckDependencyEventParameter();
$param->setCacheTime(isset($data[3]) ? $data[3] : 0);
$this->onCheckDependency($param);
$this->_dataCached = $param->getIsValid();
} else {
$this->_dataCached = false;
}
if ($this->_dataCached) {
list($this->_contents, $this->_state, $this->_actions, $this->_cacheTime) = $data;
}
}
}
}
}