|
|
@@ -195,6 +195,22 @@ class Redis extends Driver
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
+ * 批量删除缓存
|
|
|
+ * @access public
|
|
|
+ * @param string $name 缓存变量名
|
|
|
+ * @return boolean
|
|
|
+ */
|
|
|
+ public function rms($name)
|
|
|
+ {
|
|
|
+ if(strpos($name, '*') !== false){
|
|
|
+ $key = $this->handler->keys($this->getCacheKey($name));
|
|
|
+ }else{
|
|
|
+ $key = $this->getCacheKey($name);
|
|
|
+ }
|
|
|
+ return $this->handler->delete($key);
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
* 清除缓存
|
|
|
* @access public
|
|
|
* @param string $tag 标签名
|