mirror of
https://github.com/predis/predis.git
synced 2026-09-03 22:36:44 +00:00
New command: SETEX (Redis v2.0-dev).
This commit is contained in:
@@ -1457,6 +1457,8 @@ class RedisServer_vNext extends RedisServer_v1_2 {
|
||||
'discard' => '\Predis\Commands\Discard',
|
||||
|
||||
/* commands operating on string values */
|
||||
'setex' => '\Predis\Commands\SetExpire',
|
||||
'setExpire' => '\Predis\Commands\SetExpire',
|
||||
'append' => '\Predis\Commands\Append',
|
||||
'substr' => '\Predis\Commands\Substr',
|
||||
|
||||
@@ -1810,6 +1812,10 @@ class Set extends \Predis\MultiBulkCommand {
|
||||
public function getCommandId() { return 'SET'; }
|
||||
}
|
||||
|
||||
class SetExpire extends \Predis\MultiBulkCommand {
|
||||
public function getCommandId() { return 'SETEX'; }
|
||||
}
|
||||
|
||||
class SetPreserve extends \Predis\MultiBulkCommand {
|
||||
public function getCommandId() { return 'SETNX'; }
|
||||
public function parseResponse($data) { return (bool) $data; }
|
||||
|
||||
Reference in New Issue
Block a user