mirror of
https://github.com/predis/predis.git
synced 2026-09-13 11:57:02 +00:00
New commands: PSUBSCRIBE and PUNSUBSCRIBE (Redis v2.0-dev).
This commit is contained in:
@@ -1511,6 +1511,8 @@ class RedisServer_vNext extends RedisServer_v1_2 {
|
||||
/* publish - subscribe */
|
||||
'subscribe' => '\Predis\Commands\Subscribe',
|
||||
'unsubscribe' => '\Predis\Commands\Unsubscribe',
|
||||
'psubscribe' => '\Predis\Commands\SubscribeByPattern',
|
||||
'punsubscribe' => '\Predis\Commands\UnsubscribeByPattern',
|
||||
'publish' => '\Predis\Commands\Publish',
|
||||
|
||||
/* remote server control commands */
|
||||
@@ -2348,6 +2350,16 @@ class Unsubscribe extends \Predis\MultiBulkCommand {
|
||||
public function getCommandId() { return 'UNSUBSCRIBE'; }
|
||||
}
|
||||
|
||||
class SubscribeByPattern extends \Predis\MultiBulkCommand {
|
||||
public function canBeHashed() { return false; }
|
||||
public function getCommandId() { return 'PSUBSCRIBE'; }
|
||||
}
|
||||
|
||||
class UnsubscribeByPattern extends \Predis\MultiBulkCommand {
|
||||
public function canBeHashed() { return false; }
|
||||
public function getCommandId() { return 'PUNSUBSCRIBE'; }
|
||||
}
|
||||
|
||||
class Publish extends \Predis\MultiBulkCommand {
|
||||
public function canBeHashed() { return false; }
|
||||
public function getCommandId() { return 'PUBLISH'; }
|
||||
|
||||
Reference in New Issue
Block a user