<?php 
class cache {
   //禁止实例化
	private function __construct() {}

    public static function get($name)
    {
        return apc_fetch($name);
    }

    public static function set($name, $value, $ttl = 0)
    {
        return apc_store($name, $value, $ttl);
    }

    public static function rm($name)
    {
        return apc_delete($name);
    }

    public static function flush()
    {
        return apc_clear_cache();
    }
}
?>