(转载)apc_fetch

(转载)http://php.net/manual/zh/function.apc-fetch.php

apc_fetch

(PECL apc >= 3.0.0)

apc_fetch  从缓存中取出存储的变量

reject note 说明

mixed apc_fetch ( mixed $key [, bool &$success ] )

从缓存中取出存储的变量

reject note 参数

 

key

key 是使用 apc_store() 存储的键名。 如果传递的是一个数组,则数组中的每个元素的值都被返回

success

Set to TRUE in success and FALSE in failure.

 

reject note 返回值

存储一个变量或者一个数组失败时返回; FALSE

reject note 范例

 

Example #1 A apc_fetch() example

<?php
$bar 
'BAR';
apc_store('foo'$bar);
var_dump(apc_fetch('foo'));
?>

以上例程会输出:

string(3) "BAR"

 

reject note 更新日志

版本说明
3.0.17 The success parameter was added.

reject note 参见

 

posted @ 2013-06-17 16:49  robotke1  阅读(331)  评论(0编辑  收藏  举报