@@ -15,6 +15,11 @@ discard block |
||
15 | 15 | } |
16 | 16 | |
17 | 17 | // just here for Memcache compatibilty |
18 | + |
|
19 | + /** |
|
20 | + * @param boolean $host |
|
21 | + * @param boolean $port |
|
22 | + */ |
|
18 | 23 | public function pconnect($host, $port):bool |
19 | 24 | { |
20 | 25 | return true; |
@@ -29,6 +34,10 @@ discard block |
||
29 | 34 | return unlink($path); |
30 | 35 | } |
31 | 36 | |
37 | + /** |
|
38 | + * @param integer $flag |
|
39 | + * @param integer $expire |
|
40 | + */ |
|
32 | 41 | public function set($key, $value, $flag, $expire):bool |
33 | 42 | { |
34 | 43 | $path = $this->getKeyFilePath($key); |
@@ -70,6 +70,11 @@ discard block |
||
70 | 70 | $this->engine = new FileCache($this->root); |
71 | 71 | } |
72 | 72 | |
73 | + /** |
|
74 | + * @param string $key |
|
75 | + * |
|
76 | + * @return boolean |
|
77 | + */ |
|
73 | 78 | public function delete($key, $timeout = 0) |
74 | 79 | { |
75 | 80 | $result = @$this->engine->pconnect($this->host, $this->port); |
@@ -80,6 +85,12 @@ discard block |
||
80 | 85 | return $this->engine->delete($key, $timeout); |
81 | 86 | } |
82 | 87 | |
88 | + /** |
|
89 | + * @param string $key |
|
90 | + * @param string $value |
|
91 | + * |
|
92 | + * @return boolean |
|
93 | + */ |
|
83 | 94 | public function set($key, $value, $expire = 0, $flag = 2) |
84 | 95 | { |
85 | 96 | $result = @$this->engine->pconnect($this->host, $this->port); |
@@ -90,6 +101,11 @@ discard block |
||
90 | 101 | return $this->engine->set($key, $value, $flag, $expire); |
91 | 102 | } |
92 | 103 | |
104 | + /** |
|
105 | + * @param string $key |
|
106 | + * |
|
107 | + * @return boolean |
|
108 | + */ |
|
93 | 109 | public function get($key, $flag = 2) |
94 | 110 | { |
95 | 111 | $result = @$this->engine->pconnect($this->host, $this->port); |
@@ -100,6 +116,9 @@ discard block |
||
100 | 116 | return $this->engine->get($key, $flag); |
101 | 117 | } |
102 | 118 | |
119 | + /** |
|
120 | + * @param string $key |
|
121 | + */ |
|
103 | 122 | public function getSetGet($key, Closure $callback, $ttl = 0, $flag = 2) |
104 | 123 | { |
105 | 124 | $result = @$this->engine->pconnect($this->host, $this->port); |