public function setFile($file, $fileContent) { $file = $this->cacheDirectory->getRelativePathTo($file); $hash = $this->calcHash($fileContent); if ($this->isDryRun && $this->cache->has($file) && $this->cache->get($file) !== $hash) { $this->cache->clear($file); return; } $this->cache->set($file, $hash); }
public function clear() { if ($this->wrappedCache->canFilter()) { return $this->wrappedCache->filter($this->prefix); } else { return $this->wrappedCache->clear(); } }
/** * @inheritdoc */ public function clear() { $start = microtime(true); $this->instance->clear(); $this->update_stats(__FUNCTION__, $start, ''); }