| API Call | $object->append($key, $value [, $expiry ] [, $casunique ] [, $persistto ] [, $replicateto ]) | ||
| Asynchronous | no | ||
| Description | Append a value to an existing key | ||
| Returns | scalar; supported values: | ||
COUCHBASE_E2BIG | The Object is too big to be stored on the server | ||
COUCHBASE_ENOMEM | Out of Resources | ||
COUCHBASE_ETMPFAIL | Temporary failure; try the operation again | ||
COUCHBASE_KEY_ENOENT | Requested document ID does not exist | ||
COUCHBASE_NOT_MY_VBUCKET | The command was sent to the wrong server; may be triggered during a rebalance or failover operation. Retry the operation | ||
COUCHBASE_NOT_STORED | The object was not stored | ||
docid | Document ID on success | ||
| Arguments | |||
string $key | Document ID used to identify the value | ||
object $value | Value to be stored | ||
$expiry | Expiry time for key. Values larger than 30*24*60*60 seconds (30 days) are interpreted as absolute times (from the epoch). | ||
$casunique | Unique value used to verify a key/value combination | ||
$persistto | Specify the number of nodes on which the document must be persisted to before returning. | ||
$replicateto | Specify the number of nodes on which the document must be replicated to before returning | ||
| Errors | |||
CouchbaseAuthenticationException | Authentication to the Couchbase cluster failed | ||
CouchbaseException | Base exception class for all Couchbase exceptions | ||
CouchbaseIllegalKeyException | The key provided is not a legal key identifier | ||
CouchbaseLibcouchbaseException | An error occurred within the libcouchbase library used by th PHP extension | ||
CouchbaseServerException | An error occurred within the Couchbase cluster | ||
| API Call | $object->prepend($key, $value [, $expiry ] [, $casunique ] [, $persistto ] [, $replicateto ]) | ||
| Asynchronous | no | ||
| Description | Prepend a value to an existing key | ||
| Returns | scalar; supported values: | ||
COUCHBASE_E2BIG | The Object is too big to be stored on the server | ||
COUCHBASE_ENOMEM | Out of Resources | ||
COUCHBASE_ETMPFAIL | Temporary failure; try the operation again | ||
COUCHBASE_KEY_ENOENT | Requested document ID does not exist | ||
COUCHBASE_NOT_MY_VBUCKET | The command was sent to the wrong server; may be triggered during a rebalance or failover operation. Retry the operation | ||
COUCHBASE_NOT_STORED | The object was not stored | ||
docid | Document ID on success | ||
| Arguments | |||
string $key | Document ID used to identify the value | ||
object $value | Value to be stored | ||
$expiry | Expiry time for key. Values larger than 30*24*60*60 seconds (30 days) are interpreted as absolute times (from the epoch). | ||
$casunique | Unique value used to verify a key/value combination | ||
$persistto | Specify the number of nodes on which the document must be persisted to before returning. | ||
$replicateto | Specify the number of nodes on which the document must be replicated to before returning | ||
| Errors | |||
CouchbaseAuthenticationException | Authentication to the Couchbase cluster failed | ||
CouchbaseException | Base exception class for all Couchbase exceptions | ||
CouchbaseIllegalKeyException | The key provided is not a legal key identifier | ||
CouchbaseLibcouchbaseException | An error occurred within the libcouchbase library used by th PHP extension | ||
CouchbaseServerException | An error occurred within the Couchbase cluster | ||