private function getCache($type) { $this->cache = Gloft_Driver_Cache_Factory::getInstance($type); return $this->cache; }
protected static function cacheDel($key, $type = 'kv') { $flag = true; if ('kv' == $type || 'both' == $type) { $kv = Gloft_Driver_Cache_Factory::getInstance(Gloft_Driver_Cache_Factory::TYPE_KV); $flag = $flag && $kv->del($key); } if (false === $flag) { return $flag; } if ('mem' == $type || 'mem' == $type) { $mem = Gloft_Driver_Cache_Factory::getInstance(Gloft_Driver_Cache_Factory::TYPE_MEM); $flag = $flag && $mem->del($key); } return $flag; }