1 | <?php /** MicroMemcachedDriver */ |
||
19 | class MemcachedDriver extends CacheDriver |
||
20 | { |
||
21 | /** @var \Memcache|\Memcached $driver driver memcache(d) */ |
||
22 | protected $driver; |
||
23 | |||
24 | |||
25 | /** |
||
26 | * Constructor |
||
27 | * |
||
28 | * @access public |
||
29 | * |
||
30 | * @param array $config config array |
||
31 | * |
||
32 | * @result void |
||
33 | * @throws Exception |
||
34 | */ |
||
35 | public function __construct(array $config = []) |
||
75 | |||
76 | /** |
||
77 | * @inheritdoc |
||
78 | */ |
||
79 | public function check() |
||
83 | |||
84 | /** |
||
85 | * Destructor |
||
86 | * |
||
87 | * @access public |
||
88 | * @result void |
||
89 | */ |
||
90 | public function __destruct() |
||
96 | |||
97 | /** |
||
98 | * @inheritdoc |
||
99 | */ |
||
100 | public function get($name) |
||
106 | |||
107 | /** |
||
108 | * @inheritdoc |
||
109 | */ |
||
110 | public function set($name, $value, $duration = 0) |
||
123 | |||
124 | /** |
||
125 | * @inheritdoc |
||
126 | */ |
||
127 | public function delete($name) |
||
131 | |||
132 | /** |
||
133 | * @inheritdoc |
||
134 | */ |
||
135 | public function clean() |
||
139 | |||
140 | /** |
||
141 | * @inheritdoc |
||
142 | */ |
||
143 | public function info() |
||
147 | |||
148 | /** |
||
149 | * @inheritdoc |
||
150 | */ |
||
151 | public function getMeta($id) |
||
162 | |||
163 | /** |
||
164 | * @inheritdoc |
||
165 | */ |
||
166 | public function increment($name, $offset = 1) |
||
170 | |||
171 | /** |
||
172 | * @inheritdoc |
||
173 | */ |
||
174 | public function decrement($name, $offset = 1) |
||
178 | } |
||
179 |
It seems like the method you are trying to call exists only in some of the possible types.
Let’s take a look at an example:
Available Fixes
Add an additional type-check:
Only allow a single type to be passed if the variable comes from a parameter: