array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'en', ), 'this' => array ( 0 => 'memcached.getresultcode.php', 1 => 'Memcached::getResultCode', ), 'up' => array ( 0 => 'class.memcached.php', 1 => 'Memcached', ), 'prev' => array ( 0 => 'memcached.getoption.php', 1 => 'Memcached::getOption', ), 'next' => array ( 0 => 'memcached.getresultmessage.php', 1 => 'Memcached::getResultMessage', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/memcached/memcached/getresultcode.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PECL memcached >= 0.1.0)
Memcached::getResultCode — Return the result code of the last operation
Memcached::getResultCode() returns one of the
Memcached::RES_*
constants that is the result of the
last executed Memcached method.
This function has no parameters.
Result code of the last Memcached operation.
Example #1 Memcached::getResultCode() example
<?php
$m = new Memcached();
$m->addServer('localhost', 11211);
$m->add('foo', 'bar');
if ($m->getResultCode() == Memcached::RES_NOTSTORED) {
/* ... */
}
?>