From 269007e0f5cbe398e94856509963a0b3c6144b58 Mon Sep 17 00:00:00 2001 From: Andrei Zmievski Date: Tue, 3 Feb 2009 00:59:04 +0000 Subject: [PATCH] memcached docs progress git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@275074 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/memcached/memcached/add.xml | 50 +++++++------------- reference/memcached/memcached/addbykey.xml | 54 ++++++++-------------- reference/memcached/memcached/set.xml | 8 ++-- reference/memcached/memcached/setbykey.xml | 4 +- 4 files changed, 44 insertions(+), 72 deletions(-) diff --git a/reference/memcached/memcached/add.xml b/reference/memcached/memcached/add.xml index 1c73ca5c8f..d365ccfb29 100644 --- a/reference/memcached/memcached/add.xml +++ b/reference/memcached/memcached/add.xml @@ -1,22 +1,24 @@ - + Memcached::add - The add purpose + Add data under a new key &reftitle.description; - public voidMemcached::add + public boolMemcached::add stringkey - stringvalue - stringexpiration + mixedvalue + intexpiration - The method description goes here. + Memcached::add is similar to + Memcached::set, but the operation fails if the + key already exists on the server. @@ -28,7 +30,7 @@ key - Description... + The key under which to store the value. @@ -36,7 +38,7 @@ value - Description... + The value to store. @@ -44,7 +46,7 @@ expiration - Description... + The expiration time of the value, as a Unix timestamp. @@ -55,29 +57,9 @@ &reftitle.returnvalues; - Description... - - - - - &reftitle.examples; - - - <function>Memcached::add</function> example - - -]]> - - &example.outputs.similar; - - - - + &return.success; + The Memcached::getResultCode will return + Memcached::RES_NOTSTORED if the key already exists. @@ -85,7 +67,9 @@ &reftitle.seealso; - Classname::Method + Memcached::addByKey + Memcached::set + Memcached::replace diff --git a/reference/memcached/memcached/addbykey.xml b/reference/memcached/memcached/addbykey.xml index daab44877a..ed53b766f5 100644 --- a/reference/memcached/memcached/addbykey.xml +++ b/reference/memcached/memcached/addbykey.xml @@ -1,23 +1,27 @@ - + Memcached::addByKey - The addByKey purpose + Add data under a new key on a specific server &reftitle.description; - public voidMemcached::addByKey + public boolMemcached::addByKey stringserver_key stringkey - stringvalue - stringexpiration + mixedvalue + intexpiration - The method description goes here. + Memcached::addByKey is functionally equivalent to + Memcached::add, except that the free-form + server_key can be used to map the + key to a specific server. This is useful if you need + to keep a bunch of related keys on a certain server. @@ -29,7 +33,7 @@ server_key - Description... + The key identifying the server to store the value on. @@ -37,7 +41,7 @@ key - Description... + The key under which to store the value. @@ -45,7 +49,7 @@ value - Description... + The value to store. @@ -53,7 +57,7 @@ expiration - Description... + The expiration time of the value, as a Unix timestamp. @@ -64,29 +68,9 @@ &reftitle.returnvalues; - Description... - - - - - &reftitle.examples; - - - <function>Memcached::addByKey</function> example - - -]]> - - &example.outputs.similar; - - - - + &return.success; + The Memcached::getResultCode will return + Memcached::RES_NOTSTORED if the key already exists. @@ -94,7 +78,9 @@ &reftitle.seealso; - Classname::Method + Memcached::add + Memcached::set + Memcached::replace diff --git a/reference/memcached/memcached/set.xml b/reference/memcached/memcached/set.xml index d3dd487acb..c409ada460 100644 --- a/reference/memcached/memcached/set.xml +++ b/reference/memcached/memcached/set.xml @@ -1,10 +1,10 @@ - + Memcached::set - Store data for a key + Store data under a key @@ -24,7 +24,7 @@ server deletes it to make space for new items. The value can be any valid PHP type except for resources, because those cannot be represented in a serialized form. If the - OPT_COMPRESSION option is turned on, the serialized + Memcached::OPT_COMPRESSION option is turned on, the serialized value will also be compressed before storage. @@ -118,6 +118,8 @@ object(stdClass)#1 (0) { Memcached::setByKey + Memcached::add + Memcached::replace diff --git a/reference/memcached/memcached/setbykey.xml b/reference/memcached/memcached/setbykey.xml index 2daf8d7547..f44b5ee5a6 100644 --- a/reference/memcached/memcached/setbykey.xml +++ b/reference/memcached/memcached/setbykey.xml @@ -1,10 +1,10 @@ - + Memcached::setByKey - Store data for a key on a specific server + Store data under a key on a specific server