Sfoglia il codice sorgente

New command: HINCRBY (Redis v2.0-dev).

Daniele Alessandri 15 anni fa
parent
commit
17dff871bc
1 ha cambiato i file con 6 aggiunte e 0 eliminazioni
  1. 6 0
      lib/Predis.php

+ 6 - 0
lib/Predis.php

@@ -1230,6 +1230,8 @@ class RedisServer_vNext extends RedisServer_v1_2 {
             /* commands operating on hashes */
             'hset'                      => '\Predis\Commands\HashSet',
                 'hashSet'               => '\Predis\Commands\HashSet',
+            'hincrby'                   => '\Predis\Commands\HashIncrementBy',
+                'hashIncrementBy'       => '\Predis\Commands\HashIncrementBy',
             'hget'                      => '\Predis\Commands\HashGet',
                 'hashGet'               => '\Predis\Commands\HashGet',
             'hdel'                      => '\Predis\Commands\HashDelete',
@@ -1762,6 +1764,10 @@ class HashSet extends \Predis\MultiBulkCommand {
     public function getCommandId() { return 'HSET'; }
 }
 
+class HashIncrementBy extends \Predis\InlineCommand {
+    public function getCommandId() { return 'HINCRBY'; }
+}
+
 class HashGet extends \Predis\BulkCommand {
     public function getCommandId() { return 'HGET'; }
 }