📄 cache_memcache.class.php
字号:
<?php
class cache
{
var $memcache;
function __construct()
{
$this->memcache = &new Memcache;
$this->memcache->pconnect(MEMCACHE_HOST, MEMCACHE_PORT, MEMCACHE_TIMEOUT);
}
function cache()
{
$this->__construct();
}
function get($name)
{
return $this->memcache->get($name);
}
function set($name, $value, $ttl = 0)
{
return $this->memcache->set($name, $value, 0, $ttl);
}
function rm($name)
{
return $this->memcache->delete($name);
}
function clear()
{
return $this->memcache->flush();
}
}
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -