|
|
@ -17,6 +17,9 @@ class MemcacheCache extends Cache |
|
|
|
*/ |
|
|
|
protected $connection = null; |
|
|
|
|
|
|
|
/** |
|
|
|
* @var null|string |
|
|
|
*/ |
|
|
|
protected $key_salt = null; |
|
|
|
|
|
|
|
/** |
|
|
@ -26,7 +29,6 @@ class MemcacheCache extends Cache |
|
|
|
*/ |
|
|
|
protected $expire = 3600; |
|
|
|
|
|
|
|
|
|
|
|
public function __construct($config) |
|
|
|
{ |
|
|
|
$this->connection = new Memcache(); |
|
|
@ -76,7 +78,7 @@ class MemcacheCache extends Cache |
|
|
|
* Delete item from the cache |
|
|
|
* |
|
|
|
* @param string $key |
|
|
|
* @param int $value |
|
|
|
* @internal param int $value |
|
|
|
* @return bool |
|
|
|
*/ |
|
|
|
public function del($key) |
|
|
@ -121,8 +123,9 @@ class MemcacheCache extends Cache |
|
|
|
* Replace value of the existing item |
|
|
|
* |
|
|
|
* @param string $key |
|
|
|
* @param mixed $var |
|
|
|
* @param mixed $value |
|
|
|
* @param int $expire |
|
|
|
* @internal param mixed $var |
|
|
|
* @return bool |
|
|
|
*/ |
|
|
|
public function replace($key, $value, $expire = 0) |
|
|
|