Skip to content

Commit c522307

Browse files
committed
Tagging bugfix and updated tests to ^0.9
1 parent b877e64 commit c522307

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

MemcachedCachePool.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ public function __construct(\Memcached $cache)
3838
$this->cache->setOption(\Memcached::OPT_BINARY_PROTOCOL, true);
3939
}
4040

41+
/**
42+
* {@inheritdoc}
43+
*/
4144
protected function fetchObjectFromCache($key)
4245
{
4346
if (false === $result = unserialize($this->cache->get($this->getHierarchyKey($key)))) {
@@ -47,11 +50,17 @@ protected function fetchObjectFromCache($key)
4750
return $result;
4851
}
4952

53+
/**
54+
* {@inheritdoc}
55+
*/
5056
protected function clearAllObjectsFromCache()
5157
{
5258
return $this->cache->flush();
5359
}
5460

61+
/**
62+
* {@inheritdoc}
63+
*/
5564
protected function clearOneObjectFromCache($key)
5665
{
5766
$this->commit();
@@ -67,6 +76,9 @@ protected function clearOneObjectFromCache($key)
6776
return $this->cache->getResultCode() === \Memcached::RES_NOTFOUND;
6877
}
6978

79+
/**
80+
* {@inheritdoc}
81+
*/
7082
protected function storeItemInCache(CacheItemInterface $item, $ttl)
7183
{
7284
if ($ttl === null) {
@@ -80,6 +92,9 @@ protected function storeItemInCache(CacheItemInterface $item, $ttl)
8092
return $this->cache->set($key, serialize([true, $item->get(), []]), $ttl);
8193
}
8294

95+
/**
96+
* {@inheritdoc}
97+
*/
8398
protected function getValueFormStore($key)
8499
{
85100
return $this->cache->get($key);

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
"php": "^5.5|^7.0",
2828
"ext-memcached": "*",
2929
"psr/cache": "^1.0",
30-
"cache/adapter-common": "^0.2",
31-
"cache/taggable-cache": "^0.3",
30+
"cache/adapter-common": "^0.3",
31+
"cache/taggable-cache": "^0.4",
3232
"cache/hierarchical-cache": "^0.2"
3333
},
3434
"require-dev": {
3535
"phpunit/phpunit": "^4.0|^5.1",
36-
"cache/integration-tests": "0.9.0"
36+
"cache/integration-tests": "^0.9"
3737
},
3838
"provide": {
3939
"psr/cache-implementation": "^1.0"

0 commit comments

Comments
 (0)