Added bitcount to standard interfaces and bitop to MultiKey interfaces (since it is non-shardable)

Merge branch 'impl-bitcount-and-bitop' of git://github.com/koron/jedis

Conflicts:
	src/main/java/redis/clients/jedis/JedisCommands.java
This commit is contained in:
samhendley
2013-01-09 23:48:23 -05:00
21 changed files with 262 additions and 9 deletions

View File

@@ -1388,5 +1388,35 @@ public class Pipeline extends Queable implements
public Response<String> select(int index){
client.select(index);
return getResponse(BuilderFactory.STRING);
}
}
public Response<Long> bitcount(String key) {
client.bitcount(key);
return getResponse(BuilderFactory.LONG);
}
public Response<Long> bitcount(String key, long start, long end) {
client.bitcount(key, start, end);
return getResponse(BuilderFactory.LONG);
}
public Response<Long> bitcount(byte[] key) {
client.bitcount(key);
return getResponse(BuilderFactory.LONG);
}
public Response<Long> bitcount(byte[] key, long start, long end) {
client.bitcount(key, start, end);
return getResponse(BuilderFactory.LONG);
}
public Response<Long> bitop(BitOP op, byte[] destKey, byte[]... srcKeys) {
client.bitop(op, destKey, srcKeys);
return getResponse(BuilderFactory.LONG);
}
public Response<Long> bitop(BitOP op, String destKey, String... srcKeys) {
client.bitop(op, destKey, srcKeys);
return getResponse(BuilderFactory.LONG);
}
}