Extends
lithium\core\Object
Delete value from the cache
Parameters
- string $key The key to uniquely identify the cached item.
Returns
closure Function returning boolean `true` on successful delete, `false` otherwise.Source
public function delete($key) {
$cache =& $this->_cache;
return function($self, $params) use (&$cache) {
extract($params);
if (isset($cache[$key])) {
unset($cache[$key]);
return true;
} else {
return false;
}
};
}