diff --git a/README.markdown b/README.markdown index ee253b6d..add086f5 100644 --- a/README.markdown +++ b/README.markdown @@ -99,7 +99,7 @@ class that matches the command type and its behaviour and then bind it to a client instance at runtime. Actually, it is easier done than said: class BrandNewRedisCommand extends Predis\Commands\Command { - public function getCommandId() { return 'NEWCMD'; } + public function getId() { return 'NEWCMD'; } } $redis = new Predis\Client(); diff --git a/examples/SimpleDebuggableConnection.php b/examples/SimpleDebuggableConnection.php index 8b486be1..9005d5c7 100644 --- a/examples/SimpleDebuggableConnection.php +++ b/examples/SimpleDebuggableConnection.php @@ -17,7 +17,7 @@ class SimpleDebuggableConnection extends StreamConnection { private function storeDebug(ICommand $command, $direction) { $firtsArg = $command->getArgument(0); $timestamp = round(microtime(true) - $this->_tstart, 4); - $debug = $command->getCommandId(); + $debug = $command->getId(); $debug .= isset($firtsArg) ? " $firtsArg " : ' '; $debug .= "$direction $this"; $debug .= " [{$timestamp}s]"; diff --git a/lib/Predis/Commands/Append.php b/lib/Predis/Commands/Append.php index d0d12da9..006ef067 100644 --- a/lib/Predis/Commands/Append.php +++ b/lib/Predis/Commands/Append.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Append extends Command { - public function getCommandId() { return 'APPEND'; } + public function getId() { return 'APPEND'; } } diff --git a/lib/Predis/Commands/Auth.php b/lib/Predis/Commands/Auth.php index 1295bda0..9c09580b 100644 --- a/lib/Predis/Commands/Auth.php +++ b/lib/Predis/Commands/Auth.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Auth extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'AUTH'; } + public function getId() { return 'AUTH'; } } diff --git a/lib/Predis/Commands/BackgroundRewriteAppendOnlyFile.php b/lib/Predis/Commands/BackgroundRewriteAppendOnlyFile.php index 8a9c0920..55ca89e2 100644 --- a/lib/Predis/Commands/BackgroundRewriteAppendOnlyFile.php +++ b/lib/Predis/Commands/BackgroundRewriteAppendOnlyFile.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class BackgroundRewriteAppendOnlyFile extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'BGREWRITEAOF'; } + public function getId() { return 'BGREWRITEAOF'; } public function parseResponse($data) { return $data == 'Background append only file rewriting started'; } diff --git a/lib/Predis/Commands/BackgroundSave.php b/lib/Predis/Commands/BackgroundSave.php index c61f6d46..c166d4fc 100644 --- a/lib/Predis/Commands/BackgroundSave.php +++ b/lib/Predis/Commands/BackgroundSave.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class BackgroundSave extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'BGSAVE'; } + public function getId() { return 'BGSAVE'; } public function parseResponse($data) { if ($data == 'Background saving started') { return true; diff --git a/lib/Predis/Commands/Command.php b/lib/Predis/Commands/Command.php index b5982d63..31fa1045 100644 --- a/lib/Predis/Commands/Command.php +++ b/lib/Predis/Commands/Command.php @@ -71,6 +71,6 @@ abstract class Command implements ICommand { $acc .= " $arg"; return $acc; }; - return array_reduce($this->getArguments(), $reducer, $this->getCommandId()); + return array_reduce($this->getArguments(), $reducer, $this->getId()); } } diff --git a/lib/Predis/Commands/Config.php b/lib/Predis/Commands/Config.php index a69cde06..122d4fdf 100644 --- a/lib/Predis/Commands/Config.php +++ b/lib/Predis/Commands/Config.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Config extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'CONFIG'; } + public function getId() { return 'CONFIG'; } } diff --git a/lib/Predis/Commands/DatabaseSize.php b/lib/Predis/Commands/DatabaseSize.php index e14921df..7a1e3aaf 100644 --- a/lib/Predis/Commands/DatabaseSize.php +++ b/lib/Predis/Commands/DatabaseSize.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class DatabaseSize extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'DBSIZE'; } + public function getId() { return 'DBSIZE'; } } diff --git a/lib/Predis/Commands/Decrement.php b/lib/Predis/Commands/Decrement.php index 191c649e..e0dabac3 100644 --- a/lib/Predis/Commands/Decrement.php +++ b/lib/Predis/Commands/Decrement.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Decrement extends Command { - public function getCommandId() { return 'DECR'; } + public function getId() { return 'DECR'; } } diff --git a/lib/Predis/Commands/DecrementBy.php b/lib/Predis/Commands/DecrementBy.php index fa6a1fc1..a2784ba1 100644 --- a/lib/Predis/Commands/DecrementBy.php +++ b/lib/Predis/Commands/DecrementBy.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class DecrementBy extends Command { - public function getCommandId() { return 'DECRBY'; } + public function getId() { return 'DECRBY'; } } diff --git a/lib/Predis/Commands/Delete.php b/lib/Predis/Commands/Delete.php index a09a2b69..ba5cd5eb 100644 --- a/lib/Predis/Commands/Delete.php +++ b/lib/Predis/Commands/Delete.php @@ -5,7 +5,7 @@ namespace Predis\Commands; use Predis\Utils; class Delete extends Command { - public function getCommandId() { return 'DEL'; } + public function getId() { return 'DEL'; } public function filterArguments(Array $arguments) { return Utils::filterArrayArguments($arguments); } diff --git a/lib/Predis/Commands/Discard.php b/lib/Predis/Commands/Discard.php index 6f11efaf..f73312ab 100644 --- a/lib/Predis/Commands/Discard.php +++ b/lib/Predis/Commands/Discard.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Discard extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'DISCARD'; } + public function getId() { return 'DISCARD'; } } diff --git a/lib/Predis/Commands/DoEcho.php b/lib/Predis/Commands/DoEcho.php index bd093c5c..a929d9c7 100644 --- a/lib/Predis/Commands/DoEcho.php +++ b/lib/Predis/Commands/DoEcho.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class DoEcho extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'ECHO'; } + public function getId() { return 'ECHO'; } } diff --git a/lib/Predis/Commands/Exec.php b/lib/Predis/Commands/Exec.php index 494a587f..7bef7edd 100644 --- a/lib/Predis/Commands/Exec.php +++ b/lib/Predis/Commands/Exec.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Exec extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'EXEC'; } + public function getId() { return 'EXEC'; } } diff --git a/lib/Predis/Commands/Exists.php b/lib/Predis/Commands/Exists.php index 3f5048d5..4b2c840c 100644 --- a/lib/Predis/Commands/Exists.php +++ b/lib/Predis/Commands/Exists.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class Exists extends Command { - public function getCommandId() { return 'EXISTS'; } + public function getId() { return 'EXISTS'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/Expire.php b/lib/Predis/Commands/Expire.php index 48335650..3172b168 100644 --- a/lib/Predis/Commands/Expire.php +++ b/lib/Predis/Commands/Expire.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class Expire extends Command { - public function getCommandId() { return 'EXPIRE'; } + public function getId() { return 'EXPIRE'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/ExpireAt.php b/lib/Predis/Commands/ExpireAt.php index 60c0e708..19af372f 100644 --- a/lib/Predis/Commands/ExpireAt.php +++ b/lib/Predis/Commands/ExpireAt.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class ExpireAt extends Command { - public function getCommandId() { return 'EXPIREAT'; } + public function getId() { return 'EXPIREAT'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/FlushAll.php b/lib/Predis/Commands/FlushAll.php index 1526f410..c9a97317 100644 --- a/lib/Predis/Commands/FlushAll.php +++ b/lib/Predis/Commands/FlushAll.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class FlushAll extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'FLUSHALL'; } + public function getId() { return 'FLUSHALL'; } } diff --git a/lib/Predis/Commands/FlushDatabase.php b/lib/Predis/Commands/FlushDatabase.php index c3da6a77..084d0647 100644 --- a/lib/Predis/Commands/FlushDatabase.php +++ b/lib/Predis/Commands/FlushDatabase.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class FlushDatabase extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'FLUSHDB'; } + public function getId() { return 'FLUSHDB'; } } diff --git a/lib/Predis/Commands/Get.php b/lib/Predis/Commands/Get.php index f46aa387..4a7bde63 100644 --- a/lib/Predis/Commands/Get.php +++ b/lib/Predis/Commands/Get.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Get extends Command { - public function getCommandId() { return 'GET'; } + public function getId() { return 'GET'; } } diff --git a/lib/Predis/Commands/GetBit.php b/lib/Predis/Commands/GetBit.php index e7743fc2..8dd5f5e9 100644 --- a/lib/Predis/Commands/GetBit.php +++ b/lib/Predis/Commands/GetBit.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class GetBit extends Command { - public function getCommandId() { return 'GETBIT'; } + public function getId() { return 'GETBIT'; } } diff --git a/lib/Predis/Commands/GetMultiple.php b/lib/Predis/Commands/GetMultiple.php index afebeb40..212b5ab3 100644 --- a/lib/Predis/Commands/GetMultiple.php +++ b/lib/Predis/Commands/GetMultiple.php @@ -6,7 +6,7 @@ use Predis\Utils; class GetMultiple extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'MGET'; } + public function getId() { return 'MGET'; } public function filterArguments(Array $arguments) { return Utils::filterArrayArguments($arguments); } diff --git a/lib/Predis/Commands/GetRange.php b/lib/Predis/Commands/GetRange.php index e6ca1a4a..e6b71b38 100644 --- a/lib/Predis/Commands/GetRange.php +++ b/lib/Predis/Commands/GetRange.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class GetRange extends Command { - public function getCommandId() { return 'GETRANGE'; } + public function getId() { return 'GETRANGE'; } } diff --git a/lib/Predis/Commands/GetSet.php b/lib/Predis/Commands/GetSet.php index 89f7eef7..36f5b611 100644 --- a/lib/Predis/Commands/GetSet.php +++ b/lib/Predis/Commands/GetSet.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class GetSet extends Command { - public function getCommandId() { return 'GETSET'; } + public function getId() { return 'GETSET'; } } diff --git a/lib/Predis/Commands/HashDelete.php b/lib/Predis/Commands/HashDelete.php index 4dde2756..70af036e 100644 --- a/lib/Predis/Commands/HashDelete.php +++ b/lib/Predis/Commands/HashDelete.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class HashDelete extends Command { - public function getCommandId() { return 'HDEL'; } + public function getId() { return 'HDEL'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/HashExists.php b/lib/Predis/Commands/HashExists.php index f6e7d805..fc4b6ba8 100644 --- a/lib/Predis/Commands/HashExists.php +++ b/lib/Predis/Commands/HashExists.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class HashExists extends Command { - public function getCommandId() { return 'HEXISTS'; } + public function getId() { return 'HEXISTS'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/HashGet.php b/lib/Predis/Commands/HashGet.php index b4890747..668db489 100644 --- a/lib/Predis/Commands/HashGet.php +++ b/lib/Predis/Commands/HashGet.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class HashGet extends Command { - public function getCommandId() { return 'HGET'; } + public function getId() { return 'HGET'; } } diff --git a/lib/Predis/Commands/HashGetAll.php b/lib/Predis/Commands/HashGetAll.php index 20f29324..f0d9c3a6 100644 --- a/lib/Predis/Commands/HashGetAll.php +++ b/lib/Predis/Commands/HashGetAll.php @@ -5,7 +5,7 @@ namespace Predis\Commands; use Predis\Iterators\MultiBulkResponseTuple; class HashGetAll extends Command { - public function getCommandId() { return 'HGETALL'; } + public function getId() { return 'HGETALL'; } public function parseResponse($data) { if ($data instanceof \Iterator) { return new MultiBulkResponseTuple($data); diff --git a/lib/Predis/Commands/HashGetMultiple.php b/lib/Predis/Commands/HashGetMultiple.php index 13a3bac1..70bc8968 100644 --- a/lib/Predis/Commands/HashGetMultiple.php +++ b/lib/Predis/Commands/HashGetMultiple.php @@ -3,7 +3,7 @@ namespace Predis\Commands; class HashGetMultiple extends Command { - public function getCommandId() { return 'HMGET'; } + public function getId() { return 'HMGET'; } public function filterArguments(Array $arguments) { if (count($arguments) === 2 && is_array($arguments[1])) { $flattenedKVs = array($arguments[0]); diff --git a/lib/Predis/Commands/HashIncrementBy.php b/lib/Predis/Commands/HashIncrementBy.php index 5bec0256..910c4248 100644 --- a/lib/Predis/Commands/HashIncrementBy.php +++ b/lib/Predis/Commands/HashIncrementBy.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class HashIncrementBy extends Command { - public function getCommandId() { return 'HINCRBY'; } + public function getId() { return 'HINCRBY'; } } diff --git a/lib/Predis/Commands/HashKeys.php b/lib/Predis/Commands/HashKeys.php index 78484bf3..3d117d2d 100644 --- a/lib/Predis/Commands/HashKeys.php +++ b/lib/Predis/Commands/HashKeys.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class HashKeys extends Command { - public function getCommandId() { return 'HKEYS'; } + public function getId() { return 'HKEYS'; } } diff --git a/lib/Predis/Commands/HashLength.php b/lib/Predis/Commands/HashLength.php index 7f54065c..12b7b208 100644 --- a/lib/Predis/Commands/HashLength.php +++ b/lib/Predis/Commands/HashLength.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class HashLength extends Command { - public function getCommandId() { return 'HLEN'; } + public function getId() { return 'HLEN'; } } diff --git a/lib/Predis/Commands/HashSet.php b/lib/Predis/Commands/HashSet.php index b885f7aa..12ce8926 100644 --- a/lib/Predis/Commands/HashSet.php +++ b/lib/Predis/Commands/HashSet.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class HashSet extends Command { - public function getCommandId() { return 'HSET'; } + public function getId() { return 'HSET'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/HashSetMultiple.php b/lib/Predis/Commands/HashSetMultiple.php index 79718d03..1093b5a1 100644 --- a/lib/Predis/Commands/HashSetMultiple.php +++ b/lib/Predis/Commands/HashSetMultiple.php @@ -3,7 +3,7 @@ namespace Predis\Commands; class HashSetMultiple extends Command { - public function getCommandId() { return 'HMSET'; } + public function getId() { return 'HMSET'; } public function filterArguments(Array $arguments) { if (count($arguments) === 2 && is_array($arguments[1])) { $flattenedKVs = array($arguments[0]); diff --git a/lib/Predis/Commands/HashSetPreserve.php b/lib/Predis/Commands/HashSetPreserve.php index 694fd089..3325f366 100644 --- a/lib/Predis/Commands/HashSetPreserve.php +++ b/lib/Predis/Commands/HashSetPreserve.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class HashSetPreserve extends Command { - public function getCommandId() { return 'HSETNX'; } + public function getId() { return 'HSETNX'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/HashValues.php b/lib/Predis/Commands/HashValues.php index 5baf1601..4ced5eb2 100644 --- a/lib/Predis/Commands/HashValues.php +++ b/lib/Predis/Commands/HashValues.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class HashValues extends Command { - public function getCommandId() { return 'HVALS'; } + public function getId() { return 'HVALS'; } } diff --git a/lib/Predis/Commands/ICommand.php b/lib/Predis/Commands/ICommand.php index 582775d5..37440a1f 100644 --- a/lib/Predis/Commands/ICommand.php +++ b/lib/Predis/Commands/ICommand.php @@ -5,7 +5,7 @@ namespace Predis\Commands; use Predis\Distribution\IDistributionStrategy; interface ICommand { - public function getCommandId(); + public function getId(); public function canBeHashed(); public function getHash(IDistributionStrategy $distributor); public function setArgumentsArray(Array $arguments); diff --git a/lib/Predis/Commands/Increment.php b/lib/Predis/Commands/Increment.php index 456fadc2..dc21a817 100644 --- a/lib/Predis/Commands/Increment.php +++ b/lib/Predis/Commands/Increment.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Increment extends Command { - public function getCommandId() { return 'INCR'; } + public function getId() { return 'INCR'; } } diff --git a/lib/Predis/Commands/IncrementBy.php b/lib/Predis/Commands/IncrementBy.php index 6de74d67..e0345e3c 100644 --- a/lib/Predis/Commands/IncrementBy.php +++ b/lib/Predis/Commands/IncrementBy.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class IncrementBy extends Command { - public function getCommandId() { return 'INCRBY'; } + public function getId() { return 'INCRBY'; } } diff --git a/lib/Predis/Commands/Info.php b/lib/Predis/Commands/Info.php index 747b6eaf..c92c9b9d 100644 --- a/lib/Predis/Commands/Info.php +++ b/lib/Predis/Commands/Info.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class Info extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'INFO'; } + public function getId() { return 'INFO'; } public function parseResponse($data) { $info = array(); $infoLines = explode("\r\n", $data, -1); diff --git a/lib/Predis/Commands/Keys.php b/lib/Predis/Commands/Keys.php index f65a5bee..d7c8e5f3 100644 --- a/lib/Predis/Commands/Keys.php +++ b/lib/Predis/Commands/Keys.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Keys extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'KEYS'; } + public function getId() { return 'KEYS'; } } diff --git a/lib/Predis/Commands/LastSave.php b/lib/Predis/Commands/LastSave.php index 3e909477..46e7fe32 100644 --- a/lib/Predis/Commands/LastSave.php +++ b/lib/Predis/Commands/LastSave.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class LastSave extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'LASTSAVE'; } + public function getId() { return 'LASTSAVE'; } } diff --git a/lib/Predis/Commands/ListIndex.php b/lib/Predis/Commands/ListIndex.php index 25e4eddd..436d40c6 100644 --- a/lib/Predis/Commands/ListIndex.php +++ b/lib/Predis/Commands/ListIndex.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListIndex extends Command { - public function getCommandId() { return 'LINDEX'; } + public function getId() { return 'LINDEX'; } } diff --git a/lib/Predis/Commands/ListInsert.php b/lib/Predis/Commands/ListInsert.php index fbe4a97a..ee4a884f 100644 --- a/lib/Predis/Commands/ListInsert.php +++ b/lib/Predis/Commands/ListInsert.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListInsert extends Command { - public function getCommandId() { return 'LINSERT'; } + public function getId() { return 'LINSERT'; } } diff --git a/lib/Predis/Commands/ListLength.php b/lib/Predis/Commands/ListLength.php index db503833..53c882e1 100644 --- a/lib/Predis/Commands/ListLength.php +++ b/lib/Predis/Commands/ListLength.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListLength extends Command { - public function getCommandId() { return 'LLEN'; } + public function getId() { return 'LLEN'; } } diff --git a/lib/Predis/Commands/ListPopFirst.php b/lib/Predis/Commands/ListPopFirst.php index f78b26ae..58c1f2d2 100644 --- a/lib/Predis/Commands/ListPopFirst.php +++ b/lib/Predis/Commands/ListPopFirst.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopFirst extends Command { - public function getCommandId() { return 'LPOP'; } + public function getId() { return 'LPOP'; } } diff --git a/lib/Predis/Commands/ListPopFirstBlocking.php b/lib/Predis/Commands/ListPopFirstBlocking.php index be046d69..097026ed 100644 --- a/lib/Predis/Commands/ListPopFirstBlocking.php +++ b/lib/Predis/Commands/ListPopFirstBlocking.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopFirstBlocking extends Command { - public function getCommandId() { return 'BLPOP'; } + public function getId() { return 'BLPOP'; } } diff --git a/lib/Predis/Commands/ListPopLast.php b/lib/Predis/Commands/ListPopLast.php index c461e728..e13532c7 100644 --- a/lib/Predis/Commands/ListPopLast.php +++ b/lib/Predis/Commands/ListPopLast.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopLast extends Command { - public function getCommandId() { return 'RPOP'; } + public function getId() { return 'RPOP'; } } diff --git a/lib/Predis/Commands/ListPopLastBlocking.php b/lib/Predis/Commands/ListPopLastBlocking.php index dac87b72..11687c15 100644 --- a/lib/Predis/Commands/ListPopLastBlocking.php +++ b/lib/Predis/Commands/ListPopLastBlocking.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopLastBlocking extends Command { - public function getCommandId() { return 'BRPOP'; } + public function getId() { return 'BRPOP'; } } diff --git a/lib/Predis/Commands/ListPopLastPushHead.php b/lib/Predis/Commands/ListPopLastPushHead.php index de57614a..9e32ffd1 100644 --- a/lib/Predis/Commands/ListPopLastPushHead.php +++ b/lib/Predis/Commands/ListPopLastPushHead.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopLastPushHead extends Command { - public function getCommandId() { return 'RPOPLPUSH'; } + public function getId() { return 'RPOPLPUSH'; } } diff --git a/lib/Predis/Commands/ListPopLastPushHeadBlocking.php b/lib/Predis/Commands/ListPopLastPushHeadBlocking.php index 4c90da6c..6e43fc1a 100644 --- a/lib/Predis/Commands/ListPopLastPushHeadBlocking.php +++ b/lib/Predis/Commands/ListPopLastPushHeadBlocking.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPopLastPushHeadBlocking extends Command { - public function getCommandId() { return 'BRPOPLPUSH'; } + public function getId() { return 'BRPOPLPUSH'; } } diff --git a/lib/Predis/Commands/ListPushHead.php b/lib/Predis/Commands/ListPushHead.php index f82a9d79..26b6f9a4 100644 --- a/lib/Predis/Commands/ListPushHead.php +++ b/lib/Predis/Commands/ListPushHead.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPushHead extends Command { - public function getCommandId() { return 'LPUSH'; } + public function getId() { return 'LPUSH'; } } diff --git a/lib/Predis/Commands/ListPushHeadX.php b/lib/Predis/Commands/ListPushHeadX.php index 277178b1..ce592a8f 100644 --- a/lib/Predis/Commands/ListPushHeadX.php +++ b/lib/Predis/Commands/ListPushHeadX.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPushHeadX extends Command { - public function getCommandId() { return 'LPUSHX'; } + public function getId() { return 'LPUSHX'; } } diff --git a/lib/Predis/Commands/ListPushTail.php b/lib/Predis/Commands/ListPushTail.php index 96bd314e..b09e5c02 100644 --- a/lib/Predis/Commands/ListPushTail.php +++ b/lib/Predis/Commands/ListPushTail.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPushTail extends Command { - public function getCommandId() { return 'RPUSH'; } + public function getId() { return 'RPUSH'; } } diff --git a/lib/Predis/Commands/ListPushTailX.php b/lib/Predis/Commands/ListPushTailX.php index f37897df..badddb72 100644 --- a/lib/Predis/Commands/ListPushTailX.php +++ b/lib/Predis/Commands/ListPushTailX.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListPushTailX extends Command { - public function getCommandId() { return 'RPUSHX'; } + public function getId() { return 'RPUSHX'; } } diff --git a/lib/Predis/Commands/ListRange.php b/lib/Predis/Commands/ListRange.php index a8d0b100..55034a1b 100644 --- a/lib/Predis/Commands/ListRange.php +++ b/lib/Predis/Commands/ListRange.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListRange extends Command { - public function getCommandId() { return 'LRANGE'; } + public function getId() { return 'LRANGE'; } } diff --git a/lib/Predis/Commands/ListRemove.php b/lib/Predis/Commands/ListRemove.php index 35d07f17..296b5213 100644 --- a/lib/Predis/Commands/ListRemove.php +++ b/lib/Predis/Commands/ListRemove.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListRemove extends Command { - public function getCommandId() { return 'LREM'; } + public function getId() { return 'LREM'; } } diff --git a/lib/Predis/Commands/ListSet.php b/lib/Predis/Commands/ListSet.php index ef134427..98ab7852 100644 --- a/lib/Predis/Commands/ListSet.php +++ b/lib/Predis/Commands/ListSet.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListSet extends Command { - public function getCommandId() { return 'LSET'; } + public function getId() { return 'LSET'; } } diff --git a/lib/Predis/Commands/ListTrim.php b/lib/Predis/Commands/ListTrim.php index 126ddcc2..a5189e34 100644 --- a/lib/Predis/Commands/ListTrim.php +++ b/lib/Predis/Commands/ListTrim.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ListTrim extends Command { - public function getCommandId() { return 'LTRIM'; } + public function getId() { return 'LTRIM'; } } diff --git a/lib/Predis/Commands/MoveKey.php b/lib/Predis/Commands/MoveKey.php index 37a266ae..833dd3de 100644 --- a/lib/Predis/Commands/MoveKey.php +++ b/lib/Predis/Commands/MoveKey.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class MoveKey extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'MOVE'; } + public function getId() { return 'MOVE'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/Multi.php b/lib/Predis/Commands/Multi.php index bd56ee23..9e8d1fb5 100644 --- a/lib/Predis/Commands/Multi.php +++ b/lib/Predis/Commands/Multi.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Multi extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'MULTI'; } + public function getId() { return 'MULTI'; } } diff --git a/lib/Predis/Commands/Persist.php b/lib/Predis/Commands/Persist.php index 2ec1174f..ff0f5175 100644 --- a/lib/Predis/Commands/Persist.php +++ b/lib/Predis/Commands/Persist.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class Persist extends Command { - public function getCommandId() { return 'PERSIST'; } + public function getId() { return 'PERSIST'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/Ping.php b/lib/Predis/Commands/Ping.php index f6c62e92..0810a012 100644 --- a/lib/Predis/Commands/Ping.php +++ b/lib/Predis/Commands/Ping.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class Ping extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'PING'; } + public function getId() { return 'PING'; } public function parseResponse($data) { return $data === 'PONG' ? true : false; } diff --git a/lib/Predis/Commands/Publish.php b/lib/Predis/Commands/Publish.php index deed5db7..5e1a437b 100644 --- a/lib/Predis/Commands/Publish.php +++ b/lib/Predis/Commands/Publish.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Publish extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'PUBLISH'; } + public function getId() { return 'PUBLISH'; } } diff --git a/lib/Predis/Commands/Quit.php b/lib/Predis/Commands/Quit.php index f56d4dd5..97a485a6 100644 --- a/lib/Predis/Commands/Quit.php +++ b/lib/Predis/Commands/Quit.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class Quit extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'QUIT'; } + public function getId() { return 'QUIT'; } public function closesConnection() { return true; } } diff --git a/lib/Predis/Commands/RandomKey.php b/lib/Predis/Commands/RandomKey.php index 7dc6e2bf..23ef952f 100644 --- a/lib/Predis/Commands/RandomKey.php +++ b/lib/Predis/Commands/RandomKey.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class RandomKey extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'RANDOMKEY'; } + public function getId() { return 'RANDOMKEY'; } public function parseResponse($data) { return $data !== '' ? $data : null; } } diff --git a/lib/Predis/Commands/Rename.php b/lib/Predis/Commands/Rename.php index 1ed87e82..1cd8ea03 100644 --- a/lib/Predis/Commands/Rename.php +++ b/lib/Predis/Commands/Rename.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Rename extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'RENAME'; } + public function getId() { return 'RENAME'; } } diff --git a/lib/Predis/Commands/RenamePreserve.php b/lib/Predis/Commands/RenamePreserve.php index acfd9740..e6684bd8 100644 --- a/lib/Predis/Commands/RenamePreserve.php +++ b/lib/Predis/Commands/RenamePreserve.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class RenamePreserve extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'RENAMENX'; } + public function getId() { return 'RENAMENX'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/Save.php b/lib/Predis/Commands/Save.php index c6596ad7..b10c1ebe 100644 --- a/lib/Predis/Commands/Save.php +++ b/lib/Predis/Commands/Save.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Save extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SAVE'; } + public function getId() { return 'SAVE'; } } diff --git a/lib/Predis/Commands/SelectDatabase.php b/lib/Predis/Commands/SelectDatabase.php index 6a255b2d..851c4433 100644 --- a/lib/Predis/Commands/SelectDatabase.php +++ b/lib/Predis/Commands/SelectDatabase.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class SelectDatabase extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SELECT'; } + public function getId() { return 'SELECT'; } } diff --git a/lib/Predis/Commands/Set.php b/lib/Predis/Commands/Set.php index fc165fc0..a2fe3580 100644 --- a/lib/Predis/Commands/Set.php +++ b/lib/Predis/Commands/Set.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Set extends Command { - public function getCommandId() { return 'SET'; } + public function getId() { return 'SET'; } } diff --git a/lib/Predis/Commands/SetAdd.php b/lib/Predis/Commands/SetAdd.php index 48fd491b..b4c9ca98 100644 --- a/lib/Predis/Commands/SetAdd.php +++ b/lib/Predis/Commands/SetAdd.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class SetAdd extends Command { - public function getCommandId() { return 'SADD'; } + public function getId() { return 'SADD'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetBit.php b/lib/Predis/Commands/SetBit.php index ae990264..69c97807 100644 --- a/lib/Predis/Commands/SetBit.php +++ b/lib/Predis/Commands/SetBit.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetBit extends Command { - public function getCommandId() { return 'SETBIT'; } + public function getId() { return 'SETBIT'; } } diff --git a/lib/Predis/Commands/SetCardinality.php b/lib/Predis/Commands/SetCardinality.php index 48b6b6b6..755ce039 100644 --- a/lib/Predis/Commands/SetCardinality.php +++ b/lib/Predis/Commands/SetCardinality.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetCardinality extends Command { - public function getCommandId() { return 'SCARD'; } + public function getId() { return 'SCARD'; } } diff --git a/lib/Predis/Commands/SetDifference.php b/lib/Predis/Commands/SetDifference.php index 060de4a9..a83ad6fc 100644 --- a/lib/Predis/Commands/SetDifference.php +++ b/lib/Predis/Commands/SetDifference.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetDifference extends SetIntersection { - public function getCommandId() { return 'SDIFF'; } + public function getId() { return 'SDIFF'; } } diff --git a/lib/Predis/Commands/SetDifferenceStore.php b/lib/Predis/Commands/SetDifferenceStore.php index fad51274..6675650f 100644 --- a/lib/Predis/Commands/SetDifferenceStore.php +++ b/lib/Predis/Commands/SetDifferenceStore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetDifferenceStore extends SetIntersectionStore { - public function getCommandId() { return 'SDIFFSTORE'; } + public function getId() { return 'SDIFFSTORE'; } } diff --git a/lib/Predis/Commands/SetExpire.php b/lib/Predis/Commands/SetExpire.php index 84d5a9dc..4d056dcb 100644 --- a/lib/Predis/Commands/SetExpire.php +++ b/lib/Predis/Commands/SetExpire.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetExpire extends Command { - public function getCommandId() { return 'SETEX'; } + public function getId() { return 'SETEX'; } } diff --git a/lib/Predis/Commands/SetIntersection.php b/lib/Predis/Commands/SetIntersection.php index f3488456..6cd7740a 100644 --- a/lib/Predis/Commands/SetIntersection.php +++ b/lib/Predis/Commands/SetIntersection.php @@ -5,7 +5,7 @@ namespace Predis\Commands; use Predis\Utils; class SetIntersection extends Command { - public function getCommandId() { return 'SINTER'; } + public function getId() { return 'SINTER'; } public function filterArguments(Array $arguments) { return Utils::filterArrayArguments($arguments); } diff --git a/lib/Predis/Commands/SetIntersectionStore.php b/lib/Predis/Commands/SetIntersectionStore.php index 2bcd61aa..dc0087a6 100644 --- a/lib/Predis/Commands/SetIntersectionStore.php +++ b/lib/Predis/Commands/SetIntersectionStore.php @@ -5,7 +5,7 @@ namespace Predis\Commands; use Predis\Utils; class SetIntersectionStore extends Command { - public function getCommandId() { return 'SINTERSTORE'; } + public function getId() { return 'SINTERSTORE'; } public function filterArguments(Array $arguments) { return Utils::filterArrayArguments($arguments); } diff --git a/lib/Predis/Commands/SetIsMember.php b/lib/Predis/Commands/SetIsMember.php index 5e318c6f..a2f7981b 100644 --- a/lib/Predis/Commands/SetIsMember.php +++ b/lib/Predis/Commands/SetIsMember.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class SetIsMember extends Command { - public function getCommandId() { return 'SISMEMBER'; } + public function getId() { return 'SISMEMBER'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetMembers.php b/lib/Predis/Commands/SetMembers.php index 307f38bf..842d55d6 100644 --- a/lib/Predis/Commands/SetMembers.php +++ b/lib/Predis/Commands/SetMembers.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetMembers extends Command { - public function getCommandId() { return 'SMEMBERS'; } + public function getId() { return 'SMEMBERS'; } } diff --git a/lib/Predis/Commands/SetMove.php b/lib/Predis/Commands/SetMove.php index d0c1d117..f5d52d81 100644 --- a/lib/Predis/Commands/SetMove.php +++ b/lib/Predis/Commands/SetMove.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class SetMove extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SMOVE'; } + public function getId() { return 'SMOVE'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetMultiple.php b/lib/Predis/Commands/SetMultiple.php index 15aa58cf..8a102d81 100644 --- a/lib/Predis/Commands/SetMultiple.php +++ b/lib/Predis/Commands/SetMultiple.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class SetMultiple extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'MSET'; } + public function getId() { return 'MSET'; } public function filterArguments(Array $arguments) { if (count($arguments) === 1 && is_array($arguments[0])) { $flattenedKVs = array(); diff --git a/lib/Predis/Commands/SetMultiplePreserve.php b/lib/Predis/Commands/SetMultiplePreserve.php index 918da052..5f5850df 100644 --- a/lib/Predis/Commands/SetMultiplePreserve.php +++ b/lib/Predis/Commands/SetMultiplePreserve.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class SetMultiplePreserve extends SetMultiple { public function canBeHashed() { return false; } - public function getCommandId() { return 'MSETNX'; } + public function getId() { return 'MSETNX'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetPop.php b/lib/Predis/Commands/SetPop.php index 5dd83689..953963d2 100644 --- a/lib/Predis/Commands/SetPop.php +++ b/lib/Predis/Commands/SetPop.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetPop extends Command { - public function getCommandId() { return 'SPOP'; } + public function getId() { return 'SPOP'; } } diff --git a/lib/Predis/Commands/SetPreserve.php b/lib/Predis/Commands/SetPreserve.php index 534bca3c..d0e13c36 100644 --- a/lib/Predis/Commands/SetPreserve.php +++ b/lib/Predis/Commands/SetPreserve.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class SetPreserve extends Command { - public function getCommandId() { return 'SETNX'; } + public function getId() { return 'SETNX'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetRandomMember.php b/lib/Predis/Commands/SetRandomMember.php index 0233cb02..67b5773b 100644 --- a/lib/Predis/Commands/SetRandomMember.php +++ b/lib/Predis/Commands/SetRandomMember.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetRandomMember extends Command { - public function getCommandId() { return 'SRANDMEMBER'; } + public function getId() { return 'SRANDMEMBER'; } } diff --git a/lib/Predis/Commands/SetRange.php b/lib/Predis/Commands/SetRange.php index 6b831031..ddf88d19 100644 --- a/lib/Predis/Commands/SetRange.php +++ b/lib/Predis/Commands/SetRange.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetRange extends Command { - public function getCommandId() { return 'SETRANGE'; } + public function getId() { return 'SETRANGE'; } } diff --git a/lib/Predis/Commands/SetRemove.php b/lib/Predis/Commands/SetRemove.php index 13fc6bc3..3b143234 100644 --- a/lib/Predis/Commands/SetRemove.php +++ b/lib/Predis/Commands/SetRemove.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class SetRemove extends Command { - public function getCommandId() { return 'SREM'; } + public function getId() { return 'SREM'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/SetUnion.php b/lib/Predis/Commands/SetUnion.php index fde6d0f4..e317ca7d 100644 --- a/lib/Predis/Commands/SetUnion.php +++ b/lib/Predis/Commands/SetUnion.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetUnion extends SetIntersection { - public function getCommandId() { return 'SUNION'; } + public function getId() { return 'SUNION'; } } diff --git a/lib/Predis/Commands/SetUnionStore.php b/lib/Predis/Commands/SetUnionStore.php index bea0d530..e136f917 100644 --- a/lib/Predis/Commands/SetUnionStore.php +++ b/lib/Predis/Commands/SetUnionStore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class SetUnionStore extends SetIntersectionStore { - public function getCommandId() { return 'SUNIONSTORE'; } + public function getId() { return 'SUNIONSTORE'; } } diff --git a/lib/Predis/Commands/Shutdown.php b/lib/Predis/Commands/Shutdown.php index 525b4e86..ce0a9c3f 100644 --- a/lib/Predis/Commands/Shutdown.php +++ b/lib/Predis/Commands/Shutdown.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class Shutdown extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SHUTDOWN'; } + public function getId() { return 'SHUTDOWN'; } public function closesConnection() { return true; } } diff --git a/lib/Predis/Commands/SlaveOf.php b/lib/Predis/Commands/SlaveOf.php index 887f9f40..92697d77 100644 --- a/lib/Predis/Commands/SlaveOf.php +++ b/lib/Predis/Commands/SlaveOf.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class SlaveOf extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SLAVEOF'; } + public function getId() { return 'SLAVEOF'; } public function filterArguments(Array $arguments) { if (count($arguments) === 0 || $arguments[0] === 'NO ONE') { return array('NO', 'ONE'); diff --git a/lib/Predis/Commands/Sort.php b/lib/Predis/Commands/Sort.php index f9b6d7e7..8f61aaac 100644 --- a/lib/Predis/Commands/Sort.php +++ b/lib/Predis/Commands/Sort.php @@ -3,7 +3,7 @@ namespace Predis\Commands; class Sort extends Command { - public function getCommandId() { return 'SORT'; } + public function getId() { return 'SORT'; } public function filterArguments(Array $arguments) { if (count($arguments) === 1) { return $arguments; diff --git a/lib/Predis/Commands/Strlen.php b/lib/Predis/Commands/Strlen.php index a571659f..313eef06 100644 --- a/lib/Predis/Commands/Strlen.php +++ b/lib/Predis/Commands/Strlen.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Strlen extends Command { - public function getCommandId() { return 'STRLEN'; } + public function getId() { return 'STRLEN'; } } diff --git a/lib/Predis/Commands/Subscribe.php b/lib/Predis/Commands/Subscribe.php index 19b5a9c7..8122422a 100644 --- a/lib/Predis/Commands/Subscribe.php +++ b/lib/Predis/Commands/Subscribe.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Subscribe extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'SUBSCRIBE'; } + public function getId() { return 'SUBSCRIBE'; } } diff --git a/lib/Predis/Commands/SubscribeByPattern.php b/lib/Predis/Commands/SubscribeByPattern.php index 56197838..c1f17185 100644 --- a/lib/Predis/Commands/SubscribeByPattern.php +++ b/lib/Predis/Commands/SubscribeByPattern.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class SubscribeByPattern extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'PSUBSCRIBE'; } + public function getId() { return 'PSUBSCRIBE'; } } diff --git a/lib/Predis/Commands/Substr.php b/lib/Predis/Commands/Substr.php index 902bdedc..aeb676be 100644 --- a/lib/Predis/Commands/Substr.php +++ b/lib/Predis/Commands/Substr.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Substr extends Command { - public function getCommandId() { return 'SUBSTR'; } + public function getId() { return 'SUBSTR'; } } diff --git a/lib/Predis/Commands/TimeToLive.php b/lib/Predis/Commands/TimeToLive.php index 913796ad..c2f0575e 100644 --- a/lib/Predis/Commands/TimeToLive.php +++ b/lib/Predis/Commands/TimeToLive.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class TimeToLive extends Command { - public function getCommandId() { return 'TTL'; } + public function getId() { return 'TTL'; } } diff --git a/lib/Predis/Commands/Type.php b/lib/Predis/Commands/Type.php index 7c387184..3ff3f42e 100644 --- a/lib/Predis/Commands/Type.php +++ b/lib/Predis/Commands/Type.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class Type extends Command { - public function getCommandId() { return 'TYPE'; } + public function getId() { return 'TYPE'; } } diff --git a/lib/Predis/Commands/Unsubscribe.php b/lib/Predis/Commands/Unsubscribe.php index f2cbbb53..7ee9ef40 100644 --- a/lib/Predis/Commands/Unsubscribe.php +++ b/lib/Predis/Commands/Unsubscribe.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class Unsubscribe extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'UNSUBSCRIBE'; } + public function getId() { return 'UNSUBSCRIBE'; } } diff --git a/lib/Predis/Commands/UnsubscribeByPattern.php b/lib/Predis/Commands/UnsubscribeByPattern.php index cd18fdc7..a3211b79 100644 --- a/lib/Predis/Commands/UnsubscribeByPattern.php +++ b/lib/Predis/Commands/UnsubscribeByPattern.php @@ -4,5 +4,5 @@ namespace Predis\Commands; class UnsubscribeByPattern extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'PUNSUBSCRIBE'; } + public function getId() { return 'PUNSUBSCRIBE'; } } diff --git a/lib/Predis/Commands/Unwatch.php b/lib/Predis/Commands/Unwatch.php index c706c3fe..1cdeb164 100644 --- a/lib/Predis/Commands/Unwatch.php +++ b/lib/Predis/Commands/Unwatch.php @@ -4,6 +4,6 @@ namespace Predis\Commands; class Unwatch extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'UNWATCH'; } + public function getId() { return 'UNWATCH'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/Watch.php b/lib/Predis/Commands/Watch.php index 58d5016e..cc629ea0 100644 --- a/lib/Predis/Commands/Watch.php +++ b/lib/Predis/Commands/Watch.php @@ -4,7 +4,7 @@ namespace Predis\Commands; class Watch extends Command { public function canBeHashed() { return false; } - public function getCommandId() { return 'WATCH'; } + public function getId() { return 'WATCH'; } public function filterArguments(Array $arguments) { if (isset($arguments[0]) && is_array($arguments[0])) { return $arguments[0]; diff --git a/lib/Predis/Commands/ZSetAdd.php b/lib/Predis/Commands/ZSetAdd.php index a4d9d3ad..e9a9c050 100644 --- a/lib/Predis/Commands/ZSetAdd.php +++ b/lib/Predis/Commands/ZSetAdd.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class ZSetAdd extends Command { - public function getCommandId() { return 'ZADD'; } + public function getId() { return 'ZADD'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/ZSetCardinality.php b/lib/Predis/Commands/ZSetCardinality.php index 91a1bebd..88d100da 100644 --- a/lib/Predis/Commands/ZSetCardinality.php +++ b/lib/Predis/Commands/ZSetCardinality.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetCardinality extends Command { - public function getCommandId() { return 'ZCARD'; } + public function getId() { return 'ZCARD'; } } diff --git a/lib/Predis/Commands/ZSetCount.php b/lib/Predis/Commands/ZSetCount.php index 19555fed..7904af0f 100644 --- a/lib/Predis/Commands/ZSetCount.php +++ b/lib/Predis/Commands/ZSetCount.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetCount extends Command { - public function getCommandId() { return 'ZCOUNT'; } + public function getId() { return 'ZCOUNT'; } } diff --git a/lib/Predis/Commands/ZSetIncrementBy.php b/lib/Predis/Commands/ZSetIncrementBy.php index 90f47d38..7e9ecd21 100644 --- a/lib/Predis/Commands/ZSetIncrementBy.php +++ b/lib/Predis/Commands/ZSetIncrementBy.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetIncrementBy extends Command { - public function getCommandId() { return 'ZINCRBY'; } + public function getId() { return 'ZINCRBY'; } } diff --git a/lib/Predis/Commands/ZSetIntersectionStore.php b/lib/Predis/Commands/ZSetIntersectionStore.php index 61763730..11bc9e91 100644 --- a/lib/Predis/Commands/ZSetIntersectionStore.php +++ b/lib/Predis/Commands/ZSetIntersectionStore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetIntersectionStore extends ZSetUnionStore { - public function getCommandId() { return 'ZINTERSTORE'; } + public function getId() { return 'ZINTERSTORE'; } } diff --git a/lib/Predis/Commands/ZSetRange.php b/lib/Predis/Commands/ZSetRange.php index 3afd8a7f..3d3826e8 100644 --- a/lib/Predis/Commands/ZSetRange.php +++ b/lib/Predis/Commands/ZSetRange.php @@ -6,7 +6,7 @@ use Predis\Iterators\MultiBulkResponseTuple; class ZSetRange extends Command { private $_withScores = false; - public function getCommandId() { return 'ZRANGE'; } + public function getId() { return 'ZRANGE'; } public function filterArguments(Array $arguments) { if (count($arguments) === 4) { $lastType = gettype($arguments[3]); diff --git a/lib/Predis/Commands/ZSetRangeByScore.php b/lib/Predis/Commands/ZSetRangeByScore.php index 9e308672..8bdb2d85 100644 --- a/lib/Predis/Commands/ZSetRangeByScore.php +++ b/lib/Predis/Commands/ZSetRangeByScore.php @@ -3,7 +3,7 @@ namespace Predis\Commands; class ZSetRangeByScore extends ZSetRange { - public function getCommandId() { return 'ZRANGEBYSCORE'; } + public function getId() { return 'ZRANGEBYSCORE'; } protected function prepareOptions($options) { $opts = array_change_key_case($options, CASE_UPPER); $finalizedOpts = array(); diff --git a/lib/Predis/Commands/ZSetRank.php b/lib/Predis/Commands/ZSetRank.php index dc195d36..73adfa65 100644 --- a/lib/Predis/Commands/ZSetRank.php +++ b/lib/Predis/Commands/ZSetRank.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetRank extends Command { - public function getCommandId() { return 'ZRANK'; } + public function getId() { return 'ZRANK'; } } diff --git a/lib/Predis/Commands/ZSetRemove.php b/lib/Predis/Commands/ZSetRemove.php index 4c80b8d4..7f9398d4 100644 --- a/lib/Predis/Commands/ZSetRemove.php +++ b/lib/Predis/Commands/ZSetRemove.php @@ -3,6 +3,6 @@ namespace Predis\Commands; class ZSetRemove extends Command { - public function getCommandId() { return 'ZREM'; } + public function getId() { return 'ZREM'; } public function parseResponse($data) { return (bool) $data; } } diff --git a/lib/Predis/Commands/ZSetRemoveRangeByRank.php b/lib/Predis/Commands/ZSetRemoveRangeByRank.php index 9fda95ee..19713597 100644 --- a/lib/Predis/Commands/ZSetRemoveRangeByRank.php +++ b/lib/Predis/Commands/ZSetRemoveRangeByRank.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetRemoveRangeByRank extends Command { - public function getCommandId() { return 'ZREMRANGEBYRANK'; } + public function getId() { return 'ZREMRANGEBYRANK'; } } diff --git a/lib/Predis/Commands/ZSetRemoveRangeByScore.php b/lib/Predis/Commands/ZSetRemoveRangeByScore.php index 550b05a9..41229f51 100644 --- a/lib/Predis/Commands/ZSetRemoveRangeByScore.php +++ b/lib/Predis/Commands/ZSetRemoveRangeByScore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetRemoveRangeByScore extends Command { - public function getCommandId() { return 'ZREMRANGEBYSCORE'; } + public function getId() { return 'ZREMRANGEBYSCORE'; } } diff --git a/lib/Predis/Commands/ZSetReverseRange.php b/lib/Predis/Commands/ZSetReverseRange.php index 3468bf34..0e50639b 100644 --- a/lib/Predis/Commands/ZSetReverseRange.php +++ b/lib/Predis/Commands/ZSetReverseRange.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetReverseRange extends ZSetRange { - public function getCommandId() { return 'ZREVRANGE'; } + public function getId() { return 'ZREVRANGE'; } } diff --git a/lib/Predis/Commands/ZSetReverseRangeByScore.php b/lib/Predis/Commands/ZSetReverseRangeByScore.php index 53684178..fe9d5382 100644 --- a/lib/Predis/Commands/ZSetReverseRangeByScore.php +++ b/lib/Predis/Commands/ZSetReverseRangeByScore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetReverseRangeByScore extends ZSetRangeByScore { - public function getCommandId() { return 'ZREVRANGEBYSCORE'; } + public function getId() { return 'ZREVRANGEBYSCORE'; } } diff --git a/lib/Predis/Commands/ZSetReverseRank.php b/lib/Predis/Commands/ZSetReverseRank.php index e5a183c8..0e91a5eb 100644 --- a/lib/Predis/Commands/ZSetReverseRank.php +++ b/lib/Predis/Commands/ZSetReverseRank.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetReverseRank extends Command { - public function getCommandId() { return 'ZREVRANK'; } + public function getId() { return 'ZREVRANK'; } } diff --git a/lib/Predis/Commands/ZSetScore.php b/lib/Predis/Commands/ZSetScore.php index f953948a..d486afeb 100644 --- a/lib/Predis/Commands/ZSetScore.php +++ b/lib/Predis/Commands/ZSetScore.php @@ -3,5 +3,5 @@ namespace Predis\Commands; class ZSetScore extends Command { - public function getCommandId() { return 'ZSCORE'; } + public function getId() { return 'ZSCORE'; } } diff --git a/lib/Predis/Commands/ZSetUnionStore.php b/lib/Predis/Commands/ZSetUnionStore.php index 7a39d415..442b184f 100644 --- a/lib/Predis/Commands/ZSetUnionStore.php +++ b/lib/Predis/Commands/ZSetUnionStore.php @@ -3,7 +3,7 @@ namespace Predis\Commands; class ZSetUnionStore extends Command { - public function getCommandId() { return 'ZUNIONSTORE'; } + public function getId() { return 'ZUNIONSTORE'; } public function filterArguments(Array $arguments) { $options = array(); $argc = count($arguments); diff --git a/lib/Predis/Network/ConnectionCluster.php b/lib/Predis/Network/ConnectionCluster.php index 4e122b24..1796c62b 100644 --- a/lib/Predis/Network/ConnectionCluster.php +++ b/lib/Predis/Network/ConnectionCluster.php @@ -49,7 +49,7 @@ class ConnectionCluster implements IConnectionCluster, \IteratorAggregate { public function getConnection(ICommand $command) { if ($command->canBeHashed() === false) { throw new ClientException( - sprintf("Cannot send '%s' commands to a cluster of connections", $command->getCommandId()) + sprintf("Cannot send '%s' commands to a cluster of connections", $command->getId()) ); } return $this->_distributor->get($command->getHash($this->_distributor)); diff --git a/lib/Predis/Network/PhpiredisConnection.php b/lib/Predis/Network/PhpiredisConnection.php index b13941b9..be34cfbd 100644 --- a/lib/Predis/Network/PhpiredisConnection.php +++ b/lib/Predis/Network/PhpiredisConnection.php @@ -249,7 +249,7 @@ class PhpiredisConnection extends ConnectionBase { public function writeCommand(ICommand $command) { $cmdargs = $command->getArguments(); - array_unshift($cmdargs, $command->getCommandId()); + array_unshift($cmdargs, $command->getId()); $this->write(phpiredis_format_command($cmdargs)); } diff --git a/lib/Predis/Protocols/TextCommandSerializer.php b/lib/Predis/Protocols/TextCommandSerializer.php index 67a0b020..861724dd 100644 --- a/lib/Predis/Protocols/TextCommandSerializer.php +++ b/lib/Predis/Protocols/TextCommandSerializer.php @@ -6,7 +6,7 @@ use Predis\Commands\ICommand; class TextCommandSerializer implements ICommandSerializer { public function serialize(ICommand $command) { - $commandId = $command->getCommandId(); + $commandId = $command->getId(); $arguments = $command->getArguments(); $cmdlen = strlen($commandId);