瀏覽代碼

Implemented LPOPPUSH (Class: \Predis\Commands\ListPopPush)

Daniele Alessandri 16 年之前
父節點
當前提交
d1f6658a3d
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      lib/Predis.php

+ 6 - 0
lib/Predis.php

@@ -219,6 +219,8 @@ class Client {
                 'listSet'      => '\Predis\Commands\ListSet',
             'lrem'             => '\Predis\Commands\ListRemove',
                 'listRemove'   => '\Predis\Commands\ListRemove',
+            'lpoppush'         => '\Predis\Commands\ListPopPush',
+                'listPopPush'  => '\Predis\Commands\ListPopPush',
             'lpop'             => '\Predis\Commands\ListPopFirst',
                 'popFirst'     => '\Predis\Commands\ListPopFirst',
             'rpop'             => '\Predis\Commands\ListPopLast',
@@ -900,6 +902,10 @@ class ListRemove extends \Predis\BulkCommand {
     public function getCommandId() { return 'LREM'; }
 }
 
+class ListPopPush extends \Predis\BulkCommand {
+    public function getCommandId() { return 'LPOPPUSH'; }
+}
+
 class ListPopFirst extends \Predis\InlineCommand {
     public function getCommandId() { return 'LPOP'; }
 }