本文整理汇总了PHP中zend_disk_cache_fetch函数的典型用法代码示例。如果您正苦于以下问题:PHP zend_disk_cache_fetch函数的具体用法?PHP zend_disk_cache_fetch怎么用?PHP zend_disk_cache_fetch使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了zend_disk_cache_fetch函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: driverRead
/**
* @param \Psr\Cache\CacheItemInterface $item
* @return mixed
*/
protected function driverRead(CacheItemInterface $item)
{
$data = zend_disk_cache_fetch($item->getKey());
if ($data === false) {
return null;
}
return $data;
}
示例2: _get
protected function _get($key)
{
$data = zend_disk_cache_fetch($this->key($key));
if ($data === null) {
return self::NOT_FOUND;
}
return $data;
}
示例3: zdcFetchMulti
/**
* Fetch multiple items from Zend Data Disk Cache
*
* @param array $internalKeys
* @return array All found items
* @throws Exception\RuntimeException
*/
protected function zdcFetchMulti(array $internalKeys)
{
$items = zend_disk_cache_fetch($internalKeys);
if ($items === false) {
throw new Exception\RuntimeException("zend_disk_cache_fetch(<array>) failed");
}
return $items;
}
示例4: _fetch
/**
* Fetch data
*
* @param string $id Cache id
*/
protected function _fetch($id)
{
return zend_disk_cache_fetch($this->_options['namespace'] . '::' . $id);
}
示例5: has
/**
* {@inheritdoc}
*/
public function has($key)
{
return zend_disk_cache_fetch($key) !== false;
}
示例6: get
/**
* Get a cache variable
*
* Retrieve a variable from the cache and return it's
* value to the user.
*
* @param string $name The name of the cache variable to retrieve.
*
* @return mixed The value of the retrieved variable or false if
* variable isn't found.
*/
public function get($name)
{
return zend_disk_cache_fetch($name);
}
示例7: get
public function get($key)
{
$safeKey = $this->makeKey($key);
$ret = @zend_disk_cache_fetch($safeKey);
return $ret;
}
示例8: get
/**
* {@inheritdoc}
*/
public function get($key)
{
return zend_disk_cache_fetch($key);
}
示例9: read
/**
* Read datas with $uid key
* @param mixed $uid
* @return mixed
*/
public function read($uid)
{
return zend_disk_cache_fetch($uid);
}