Rozgłoszenie o skasowaniu klucza
@param string $key klucz
@return boolean
@throws CacheException
187418
protected final function _broadcastDelete($key)
    {
        //brak rozproszonego bufora
        if (!$this->_distributedStorage) {
            return true;
        }
        //rozgłoszenie informacji o usunięciu klucza do bufora Db i zapis o lokalnym usunięciu
        return $this->_distributedStorage->save($time = time(), $key) &&
            $this->_undistributedCache->save($time, self::DEL_PREFIX . $key, 0);
    }
503513
public function get($key)
    {
        if (isset($this->cache[$key])) {
            list($expires, $value) = $this->cache[$key];
            if (!$expires || ($expires >= microtime(true))) {
                return $value;
            }
            unset($this->cache[$key]);
        }
        return false;
    }
703213
public function getCachedRuleSet($key)
    {
        if (!$this->enabled || !$this->filesystem->exists($this->cacheDir.$key)) {
            return;
        }

        $file = new SplFileInfo($this->cacheDir.$key, null, null);

        return unserialize($file->getContents());
    }
194659
public function delete($key): bool
    {
        if ($this->enabled) {
            $realKey = $this->adjustKey($key);
            return $this->cacheDelete($realKey);
        }
        return false;
    }
691244
function getCache( $key ) {

        return isset( $this->_cache[ $key ] ) ? $this->_cache[ $key ] : null;

    }
870837
public function getFromCache($key)
  {
    $value = $this->memcache->get($this->buildMKey($key));
    if ($value) {
      return unserialize($value);
    }
    return null;
  }
796366
function check(CacheKey $key) {

		if (isset ( $this->elements [$key->getModule()] [$key->getProperty()] )) {
			return true;
		} else {
			return false;
		}
	}
69348
public function has($key)
    {
        return $this->enabled && $this->filesystem->exists($this->cacheDir.$key);
    }
1061627
public function isInCache($key)
  {
    $value = $this->memcache->get($this->buildMKey($key));
    if ($value) {
      return true;
    }
    return false;
  }
1132672
public function delete($key)
    {

        $deleted = false;

        $catalog = \array_keys($this->getKeys());
        foreach ($catalog as $k) {

            if (substr($k, 0, strlen($key)) == $key) {

                $delete = $this->memcache->delete($this->namespace . $key);
                if ($delete) {
                    $this->catalogKeyDelete($k);
                    $deleted = true;
                }
            }
        }

        return $deleted;
    }
722738
private function getSchemaCache($key)
    {
        if (isset($this->model_schema_cache[$key])) {
            return $this->model_schema_cache[$key];
        }

        return false;
    }
220977
public function containsKey($key)
    {
        if (!$this->enabled)
            return false;

        $has_key = array_key_exists($this->key($key), $this->cache);

        // $this->Logger->debug("Cache contains {$key}? " . (($has_key) ? 'TRUE' : 'FALSE'));

        return $has_key;
    }
950207
public function release_lock($key) {
        $key = $this->parse_key($key);
        if ($this->nativelocking) {
            return $this->get_store()->release_lock($key, $this->get_identifier());
        } else {
            $this->ensure_cachelock_available();
            return $this->cachelockinstance->unlock($key, $this->get_identifier());
        }
    }
963525
public function get($key)
    {
        $filePath = $this->getFilePathFromKey($key);

        if (!file_exists($filePath)) {
            return false;
        }

        if (!is_readable($filePath)) {
            return false;
        }

        $cacheFileData = file_get_contents($filePath);

        if ($this->config['gzipCompression']) {
            try {
                $cacheFileData = gzuncompress($cacheFileData);
            } catch (\Exception $e) {
                $cacheFileData = false;
            }
        }

        // Bail immediately if the file could not be read, or its data could not be uncompressed
        if (!$cacheFileData) {
            return false;
        }

        $cacheObj = json_decode($cacheFileData);

        // Unable to decode JSON
        if ($cacheObj === null) {
            return false;
        }

        // Check cache object format
        if (!isset($cacheObj->content) || !isset($cacheObj->expiryTimestamp)) {
            return false;
        }

        // Check cache content is serialized
        if (!$this->isSerialized($cacheObj->content)) {
            return false;
        }

        if (!function_exists('sys_getloadavg') && $this->config['unixLoadUpperThreshold'] !== -1) {
            throw new Exception('Your PHP installation does not support `sys_getloadavg` (Windows?). Please set `unixLoadUpperThreshold` to `-1` in your DOFileCache config.');
        }

        if ($this->config['unixLoadUpperThreshold'] == -1) {
            $unixLoad = [0 => -PHP_INT_MAX, 1 => -PHP_INT_MAX, 2 => -PHP_INT_MAX];
        } else {
            $unixLoad = sys_getloadavg();
        }

        if ($cacheObj->expiryTimestamp > time() || $unixLoad[0] >= $this->config['unixLoadUpperThreshold']) {
            // Cache item has not yet expired or system load is too high
            return unserialize($cacheObj->content);
        } else {
            // Cache item has expired
            return false;
        }
    }
586038
public static function clear($key)
    {
        $that = new static($key);

        if ($that->isCached()) {

            $deletionSuccess = unlink($that->filePath());
            
            if(!$deletionSuccess) {
                throw new CacheException(sprintf("Could not delete file '%s'", $this->filePath()));
            }
        }
    }
63915
public function read($key)
    {
        $cacheFile = $this->getCachePath($key);

        clearstatcache(true, $cacheFile);
        if (file_exists($cacheFile)) {
            $cache = file_get_contents($cacheFile);
            $cache = json_decode($cache, true);
            if ($cache['ttl'] > time()) {
                $this->remainingTtl = $cache['ttl'] - time();
                return $cache['content'];
            } else {
                $this->purge($key);
            }
        }

        return false;
    }
681341
public function isInCache($key)
  {
    $file = $this->cachePath . $this->getEncodedKey($key);
    return file_exists($file);
  }