Determine Given Key Is Exists In Storage?

@param mixed $key

@return bool
@throws exInvalidKey|exIOError
196714
function has($key)
    {
        \Poirot\Storage\assertKey($key);

        try {
            $count = $this->collection->count([
                'key'   => $key,
                'realm' => $this->getRealm(),
            ]);
        } catch (\Exception $e) {
            throw new exReadError($e->getMessage(), $e->getCode(), $e);
        }

        return ($count > 0);
    }
1207867
public function has(string $key): bool
    {
        $this->assertRead();

        return \array_key_exists($key, $this->data);
    }
556221
public function has($key)
	{
		$this->memcached->get($key);
		if ($this->memcached->getResultCode() == Memcached::RES_NOTFOUND)
		{
			return false;
		}

		return true;
	}
597948
public static function has(string $key) : bool
  {
    if ((new Cache)->retrieve($key) == null) return false;
    return true;
  }
1068573
public function containsKey($key)
    {
        if (!$this->enabled)
            return false;

        $has_key = file_exists($this->file($key));

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

        return $has_key;
    }
258378
public function exists($key)
	{
		$key = $this->normalizeKey($key);

		return array_key_exists($key, $this->items);
	}
561406
public static function has(string $key, string $storage = 'global'): bool
    {
        $fileKey = self::key($key);
        return file_exists(self::$path . '/' . $storage . '/' . $fileKey);
    }
1032045
public function exists( $key ) {
		if ( ! $this->is_valid_session() ) {
			return false;
		}

		$key = $this->get_session_key( $key );
		if ( ! array_key_exists( $key, $_SESSION ) ) {
			return false;
		}

		return ! $this->_expired( $_SESSION[ $key ] );
	}
24812
public function exists($key)
    {
        $path = $this->computePath($key);

        return $this->fileSystem->exists($path);
    }
946653
public function exists(string $key): bool
    {
        $driver = $this->getDriver();
        $exists = $driver->get($key) !== null;
        if ($this->hasEventListeners('itemExists')) {
            $this->dispatchEvent('itemExists', new \BearFramework\App\Cache\ItemExistsEventDetails($key, $exists));
        }
        if ($this->hasEventListeners('itemRequest')) {
            $this->dispatchEvent('itemRequest', new \BearFramework\App\Cache\ItemRequestEventDetails($key));
        }
        return $exists;
    }
1349419
public function has($key)
    {
        return isset($this->data[$key]) || array_key_exists($key, $this->data);
    }
242177
public function do_exists($key)
    {
        $redis = is_object($this->_redis) ? $this->_redis : $this->_getRedis();
        return (bool)$redis->exists($this->_prefix . $key);
    }
1314065
public function isExist($key = null)
	{
		return $key = is_null($key) ? false : ($this->find($key) ? true : false);
	}
1088173
public function has($key)
    {
        $keys = (func_num_args() > 1) ? func_get_args() : (array) $key;

        foreach ($keys as $key) {
            if(!array_key_exists($key, $_SESSION))
                return false;
        }

        return true;
    }
364032
public function offsetExists($key)
    {
        return isset($this->data[$key]) || array_key_exists($key, $this->data);
    }
669642
public function exists(string $key): bool
    {
        $key = $this->getKey($key);

        return cache()->has($key);
    }
376902
public function exists($key) {
        $key = $this->_encrypt($key);
        $data = $this->_memcached->get($key);
        
        return $data ? true : false;
    }