* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Cache\Adapter; use Psr\SimpleCache\CacheInterface; use Symfony\Component\Cache\PruneableInterface; use Symfony\Component\Cache\ResettableInterface; use Symfony\Component\Cache\Traits\ProxyTrait; /** * @author Nicolas Grekas */ class SimpleCacheAdapter extends AbstractAdapter implements PruneableInterface, ResettableInterface { use ProxyTrait; private $miss; public function __construct(CacheInterface $pool, $namespace = '', $defaultLifetime = 0) { parent::__construct($namespace, $defaultLifetime); $this->pool = $pool; $this->miss = new \stdClass(); } /** * {@inheritdoc} */ protected function doFetch(array $ids) { foreach ($this->pool->getMultiple($ids, $this->miss) as $key => $value) { if ($this->miss !== $value) { yield $key => $value; } } } /** * {@inheritdoc} */ protected function doHave($id) { return $this->pool->has($id); } /** * {@inheritdoc} */ protected function doClear($namespace) { return $this->pool->clear(); } /** * {@inheritdoc} */ protected function doDelete(array $ids) { return $this->pool->deleteMultiple($ids); } /** * {@inheritdoc} */ protected function doSave(array $values, $lifetime) { return $this->pool->setMultiple($values, 0 === $lifetime ? null : $lifetime); } } __halt_compiler();----SIGNATURE:----GCCdRqs3cVqZsyvO2bQ1vA9tyXGpjo7S+1vGzPJR1hQkVAVjkIvmGxhcgru4YwE/pIuM+qnp08r6nZvUpKbNW4uf/MjzJljuFwD7QtkGJBl52DfKT9w+sq6dWbK5hBP14LbRUWH8rPH4myMGxXPvbxu3mgEpOftA8L7E4PEYgvDRVMNjl5ImNWO9cWBGXZ491soEkp5ZGbn8GMSdyJoIMQZoShB0V19QehLTDNlv49GrZ91I2f1nalFH55gmfnjF58XOvoJ4Gr3OiHi7rTv/E47ucVF2lOVSTJDeZe/hxjSqeZjpFi8vwZGgigsakI3zQZ3aSl8H6EJL8jPEziWYi8Fz4iIYnzvDGfpSYcfEl9e48atiSaOidPqppTumjGxRiVMEVSmWLMxmvU4ZoCLzWtfxd+Famv1epl9qASxxxQurL+5RxiwlJ/sPBWcuHn/sDDEuQQDTv2KvyEChPR17yWCs6DUyitBi3D5EU8ygJEpB1QL+G11em35yHJqJwZHQlfjq23k1dI284cv/lwNVhuIr3dkZiXfbxfDTPY3cpGFwYq8PzakDY5sXC14OPdJm9INyUTFND9+x+oO3YuiMcl4pYvppvqBi+f693bTXzm53iQ/ERasiZacL30jz4gqZ8dizNhiljdNz3EgTJXLQserj9bj9F75aTv2MUQMGkHY=----ATTACHMENT:----ODM0NTA3MTI4NTcwNjIxNyA0OTUyNjA5ODAyMzg4NjIxIDY1NzQyNjU5MzU3Mjkw