Delete an item from the cache by its unique key.

@param string $key The unique cache key of the item to delete.

@throws \Psr\SimpleCache\InvalidArgumentException

@return bool True on success, false on error.
776562
public function delete($key)
    {
        /* If $key is not valid string throws InvalidArgumentException */
        if (!$this->isString($key)) {
            throw new InvalidArgumentException('Cache key must be not empty string');
        }

        return $this->getCollection()->delete($key);
    }
1141916
public function delete($key)
    {
		if (! $key || ! is_string($key)) {
			throw new InvalidArgumentException('Invalid cache key');
		}

		$transientKey = $this->generateTransientKey($key);
		delete_transient($transientKey);
	}
101833
public function hasItem($key)
    {
        if (!$this->isValidEntryIdentifier($key)) {
            throw new InvalidArgumentException('"' . $key . '" is not a valid cache entry identifier.', 1514738924982);
        }

        return $this->backend->has($key);
    }
306564
public function remove($key)
    {
        if (is_null($key)) {
            throw new InvalidArgumentException("Can't add NULL {$this->name}.");
        }

        if (!is_null($id = $this->search($key))) {
            unset($this->items[$id]);
            return true;
        }

        return false;
    }
364658
public function delete($key)
    {
        $key = $this->_key($key);

        return $this->_Memcached->delete($key);
    }
880129
public function delete(string $key): bool
    {
        /**
         * @var $handle \Memcache|\Memcached
         */
        $handle = $this->_handle;
        $ret = $handle->delete($key);
        Debug::setCache(static::$type, 'delete', $key, $ret);
        return $ret;
    }
103504
public function remove($key)
    {
        $result = parent::remove($key);
        if ($result) {
            $this->invalidateResolverCache();
        }

        return $result;
    }
185225
public function delete($key)
    {
        $filePath = $this->getFilePathFromKey($key);

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

        return unlink($filePath);
    }
295773
private function deleteStore($key)
    {
        if (isset($this->storage[$key])) {
            unset($this->storage[$key]);
            return $this->save();
        }

        return true;
    }
1363203
public function delete($key) {
        $filename = $key.'.cache';
        $file = $this->file_path_for_key($key);
        if (@unlink($file)) {
            unset($this->keys[$filename]);
            return true;
        }

        return false;
    }
309606
public final function deleteItem($key)
   {
       try {
           if (!$this->hasItem($key)
            || !$this->poolDeleteItem($this->pool[$key])) {
               return false;
           }
           unset($this->pool[$key]);
       } catch (InvalidArgumentException $e) {
           throw $e;
       }
       return true;
   }
668157
public function delete($key)
    {
        $file = $this->path($key);

        if ($this->fileSystem->exists($file))
        {
            $this->fileSystem->delete($file);
        }

        return true;
    }
1053577
public function forget( $key )
	{
		$success = $this->store->forget( $this->itemKey( $key ) );

		$this->fireCacheEvent( 'delete', [$key] );

		return $success;
	}
864295
public function delete($key): bool
    {
        if ($this->has($key)) {
            $this->unset($key);
            return true;
        }

        return false;
    }
1280844
public function delete($key){
		$mc=$this->getMemcache();
		if(empty($mc))return false;
		$this->queries_delete_count++;
		return $mc->delete($key);
		}
953540
public function delete($key)
    {
        $permission   =   $this->findByKey($key);
        if (! isset($permission)) {
            return true;
        }

        return $permission->delete();
    }
722425
public function delete(string $key): bool
    {
        Redis::delete(self::PREFIX . $key);
        return parent::delete($key);
    }