Cache\Namespaced\NamespacedCachePool::hasItem PHP Метод

hasItem() публичный Метод

public hasItem ( $key )
    public function hasItem($key)
    {
        $this->prefixValue($key);
        return $this->cachePool->hasItem($key);
    }

Usage Example

Пример #1
0
 public function testHasItem()
 {
     $namespace = 'ns';
     $key = 'key';
     $returnValue = true;
     $stub = $this->getHierarchyCacheStub();
     $stub->expects($this->once())->method('hasItem')->with('|' . $namespace . '|' . $key)->willReturn($returnValue);
     $pool = new NamespacedCachePool($stub, $namespace);
     $this->assertEquals($returnValue, $pool->hasItem($key));
 }