memcachesession

来源:互联网 发布:js pageyoffset 编辑:程序博客网 时间:2024/06/07 11:12
<?phpclass MemcacheSession{    private static $_instance = null;//静态单例对象    protected $_memServers = ['192.168.0.13' => 11211, '192.168.0.12' => 11211];    private function __construct($host = '', $port = 11211, $init = false)    {        !empty($host) && $_memServers = [trim($host) => $port];        $init && $this->_start();    }    public static function getInstance($host = '', $port = 11211, $init = true)    {        if (self::$_instance == null) {            self::$_instance = new self($host, $port, $init);        }        return self::$_instance;    }    private function _start()    {    }    public function addMemServer()    {    }    public function get()    {    }    public function set()    {    }    public function setSessId()    {    }    public function getSessId()    {    }}
原创粉丝点击