redis.clients.jedis
Class ShardedJedis

java.lang.Object
  extended by redis.clients.util.Sharded<Jedis,JedisShardInfo>
      extended by redis.clients.jedis.BinaryShardedJedis
          extended by redis.clients.jedis.ShardedJedis
All Implemented Interfaces:
BinaryJedisCommands, JedisCommands

public class ShardedJedis
extends BinaryShardedJedis
implements JedisCommands


Field Summary
 
Fields inherited from class redis.clients.util.Sharded
DEFAULT_KEY_TAG_PATTERN, DEFAULT_WEIGHT
 
Constructor Summary
ShardedJedis(List<JedisShardInfo> shards)
           
ShardedJedis(List<JedisShardInfo> shards, Hashing algo)
           
ShardedJedis(List<JedisShardInfo> shards, Hashing algo, Pattern keyTagPattern)
           
ShardedJedis(List<JedisShardInfo> shards, Pattern keyTagPattern)
           
 
Method Summary
 Long append(String key, String value)
           
 Long decr(String key)
           
 Long decrBy(String key, long integer)
           
 Long del(String key)
           
 void disconnect()
           
 Boolean exists(String key)
           
 Long expire(String key, int seconds)
           
 Long expireAt(String key, long unixTime)
           
 String get(String key)
           
 Boolean getbit(String key, long offset)
           
 String getrange(String key, long startOffset, long endOffset)
           
 String getSet(String key, String value)
           
 Long hdel(String key, String... fields)
           
 Boolean hexists(String key, String field)
           
 String hget(String key, String field)
           
 Map<String,String> hgetAll(String key)
           
 Long hincrBy(String key, String field, long value)
           
 Set<String> hkeys(String key)
           
 Long hlen(String key)
           
 List<String> hmget(String key, String... fields)
           
 String hmset(String key, Map<String,String> hash)
           
 Long hset(String key, String field, String value)
           
 Long hsetnx(String key, String field, String value)
           
 List<String> hvals(String key)
           
 Long incr(String key)
           
 Long incrBy(String key, long integer)
           
 String lindex(String key, long index)
           
 Long linsert(String key, BinaryClient.LIST_POSITION where, String pivot, String value)
           
 Long llen(String key)
           
 String lpop(String key)
           
 Long lpush(String key, String... strings)
           
 Long lpushx(String key, String string)
           
 List<String> lrange(String key, long start, long end)
           
 Long lrem(String key, long count, String value)
           
 String lset(String key, long index, String value)
           
 String ltrim(String key, long start, long end)
           
 String rpop(String key)
           
 Long rpush(String key, String... strings)
           
 Long rpushx(String key, String string)
           
 Long sadd(String key, String... members)
           
 Long scard(String key)
           
 String set(String key, String value)
           
 Boolean setbit(String key, long offset, boolean value)
           
 String setex(String key, int seconds, String value)
           
 Long setnx(String key, String value)
           
 Long setrange(String key, long offset, String value)
           
 Boolean sismember(String key, String member)
           
 Set<String> smembers(String key)
           
 List<String> sort(String key)
           
 List<String> sort(String key, SortingParams sortingParameters)
           
 String spop(String key)
           
 String srandmember(String key)
           
 Long srem(String key, String... members)
           
 String substr(String key, int start, int end)
           
 Long ttl(String key)
           
 String type(String key)
           
 Long zadd(String key, double score, String member)
           
 Long zadd(String key, Map<Double,String> scoreMembers)
           
 Long zcard(String key)
           
 Long zcount(String key, double min, double max)
           
 Long zcount(String key, String min, String max)
           
 Double zincrby(String key, double score, String member)
           
 Set<String> zrange(String key, long start, long end)
           
 Set<String> zrangeByScore(String key, double min, double max)
           
 Set<String> zrangeByScore(String key, double min, double max, int offset, int count)
           
 Set<String> zrangeByScore(String key, String min, String max)
           
 Set<String> zrangeByScore(String key, String min, String max, int offset, int count)
           
 Set<Tuple> zrangeByScoreWithScores(String key, double min, double max)
           
 Set<Tuple> zrangeByScoreWithScores(String key, double min, double max, int offset, int count)
           
 Set<Tuple> zrangeByScoreWithScores(String key, String min, String max)
           
 Set<Tuple> zrangeByScoreWithScores(String key, String min, String max, int offset, int count)
           
 Set<Tuple> zrangeWithScores(String key, long start, long end)
           
 Long zrank(String key, String member)
           
 Long zrem(String key, String... members)
           
 Long zremrangeByRank(String key, long start, long end)
           
 Long zremrangeByScore(String key, double start, double end)
           
 Long zremrangeByScore(String key, String start, String end)
           
 Set<String> zrevrange(String key, long start, long end)
           
 Set<String> zrevrangeByScore(String key, double max, double min)
           
 Set<String> zrevrangeByScore(String key, double max, double min, int offset, int count)
           
 Set<String> zrevrangeByScore(String key, String max, String min)
           
 Set<String> zrevrangeByScore(String key, String max, String min, int offset, int count)
           
 Set<Tuple> zrevrangeByScoreWithScores(String key, double max, double min)
           
 Set<Tuple> zrevrangeByScoreWithScores(String key, double max, double min, int offset, int count)
           
 Set<Tuple> zrevrangeByScoreWithScores(String key, String max, String min)
           
 Set<Tuple> zrevrangeByScoreWithScores(String key, String max, String min, int offset, int count)
           
 Set<Tuple> zrevrangeWithScores(String key, long start, long end)
           
 Long zrevrank(String key, String member)
           
 Double zscore(String key, String member)
           
 
Methods inherited from class redis.clients.jedis.BinaryShardedJedis
append, create, decr, decrBy, exists, expire, expireAt, get, getSet, hdel, hexists, hget, hgetAll, hincrBy, hkeys, hlen, hmget, hmset, hset, hsetnx, hvals, incr, incrBy, lindex, linsert, llen, lpop, lpush, lpushx, lrange, lrem, lset, ltrim, objectEncoding, objectIdletime, objectRefcount, pipelined, pipelined, rpop, rpush, rpushx, sadd, scard, set, setex, setnx, sismember, smembers, sort, sort, spop, srandmember, srem, substr, ttl, type, zadd, zadd, zcard, zcount, zcount, zincrby, zrange, zrangeByScore, zrangeByScore, zrangeByScoreWithScores, zrangeByScoreWithScores, zrangeByScoreWithScores, zrangeByScoreWithScores, zrangeWithScores, zrank, zrem, zremrangeByRank, zremrangeByScore, zremrangeByScore, zrevrange, zrevrangeByScore, zrevrangeByScore, zrevrangeByScore, zrevrangeByScore, zrevrangeByScoreWithScores, zrevrangeByScoreWithScores, zrevrangeByScoreWithScores, zrevrangeByScoreWithScores, zrevrangeWithScores, zrevrank, zscore
 
Methods inherited from class redis.clients.util.Sharded
getAllShardInfo, getAllShards, getKeyTag, getShard, getShard, getShardInfo, getShardInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ShardedJedis

public ShardedJedis(List<JedisShardInfo> shards)

ShardedJedis

public ShardedJedis(List<JedisShardInfo> shards,
                    Hashing algo)

ShardedJedis

public ShardedJedis(List<JedisShardInfo> shards,
                    Pattern keyTagPattern)

ShardedJedis

public ShardedJedis(List<JedisShardInfo> shards,
                    Hashing algo,
                    Pattern keyTagPattern)
Method Detail

disconnect

public void disconnect()
Overrides:
disconnect in class BinaryShardedJedis

set

public String set(String key,
                  String value)
Specified by:
set in interface JedisCommands

get

public String get(String key)
Specified by:
get in interface JedisCommands

exists

public Boolean exists(String key)
Specified by:
exists in interface JedisCommands

type

public String type(String key)
Specified by:
type in interface JedisCommands

expire

public Long expire(String key,
                   int seconds)
Specified by:
expire in interface JedisCommands

expireAt

public Long expireAt(String key,
                     long unixTime)
Specified by:
expireAt in interface JedisCommands

ttl

public Long ttl(String key)
Specified by:
ttl in interface JedisCommands

setbit

public Boolean setbit(String key,
                      long offset,
                      boolean value)
Specified by:
setbit in interface JedisCommands

getbit

public Boolean getbit(String key,
                      long offset)
Specified by:
getbit in interface JedisCommands

setrange

public Long setrange(String key,
                     long offset,
                     String value)
Specified by:
setrange in interface JedisCommands

getrange

public String getrange(String key,
                       long startOffset,
                       long endOffset)
Specified by:
getrange in interface JedisCommands

getSet

public String getSet(String key,
                     String value)
Specified by:
getSet in interface JedisCommands

setnx

public Long setnx(String key,
                  String value)
Specified by:
setnx in interface JedisCommands

setex

public String setex(String key,
                    int seconds,
                    String value)
Specified by:
setex in interface JedisCommands

decrBy

public Long decrBy(String key,
                   long integer)
Specified by:
decrBy in interface JedisCommands

decr

public Long decr(String key)
Specified by:
decr in interface JedisCommands

incrBy

public Long incrBy(String key,
                   long integer)
Specified by:
incrBy in interface JedisCommands

incr

public Long incr(String key)
Specified by:
incr in interface JedisCommands

append

public Long append(String key,
                   String value)
Specified by:
append in interface JedisCommands

substr

public String substr(String key,
                     int start,
                     int end)
Specified by:
substr in interface JedisCommands

hset

public Long hset(String key,
                 String field,
                 String value)
Specified by:
hset in interface JedisCommands

hget

public String hget(String key,
                   String field)
Specified by:
hget in interface JedisCommands

hsetnx

public Long hsetnx(String key,
                   String field,
                   String value)
Specified by:
hsetnx in interface JedisCommands

hmset

public String hmset(String key,
                    Map<String,String> hash)
Specified by:
hmset in interface JedisCommands

hmget

public List<String> hmget(String key,
                          String... fields)
Specified by:
hmget in interface JedisCommands

hincrBy

public Long hincrBy(String key,
                    String field,
                    long value)
Specified by:
hincrBy in interface JedisCommands

hexists

public Boolean hexists(String key,
                       String field)
Specified by:
hexists in interface JedisCommands

del

public Long del(String key)

hdel

public Long hdel(String key,
                 String... fields)
Specified by:
hdel in interface JedisCommands

hlen

public Long hlen(String key)
Specified by:
hlen in interface JedisCommands

hkeys

public Set<String> hkeys(String key)
Specified by:
hkeys in interface JedisCommands

hvals

public List<String> hvals(String key)
Specified by:
hvals in interface JedisCommands

hgetAll

public Map<String,String> hgetAll(String key)
Specified by:
hgetAll in interface JedisCommands

rpush

public Long rpush(String key,
                  String... strings)
Specified by:
rpush in interface JedisCommands

lpush

public Long lpush(String key,
                  String... strings)
Specified by:
lpush in interface JedisCommands

lpushx

public Long lpushx(String key,
                   String string)
Specified by:
lpushx in interface JedisCommands

rpushx

public Long rpushx(String key,
                   String string)
Specified by:
rpushx in interface JedisCommands

llen

public Long llen(String key)
Specified by:
llen in interface JedisCommands

lrange

public List<String> lrange(String key,
                           long start,
                           long end)
Specified by:
lrange in interface JedisCommands

ltrim

public String ltrim(String key,
                    long start,
                    long end)
Specified by:
ltrim in interface JedisCommands

lindex

public String lindex(String key,
                     long index)
Specified by:
lindex in interface JedisCommands

lset

public String lset(String key,
                   long index,
                   String value)
Specified by:
lset in interface JedisCommands

lrem

public Long lrem(String key,
                 long count,
                 String value)
Specified by:
lrem in interface JedisCommands

lpop

public String lpop(String key)
Specified by:
lpop in interface JedisCommands

rpop

public String rpop(String key)
Specified by:
rpop in interface JedisCommands

sadd

public Long sadd(String key,
                 String... members)
Specified by:
sadd in interface JedisCommands

smembers

public Set<String> smembers(String key)
Specified by:
smembers in interface JedisCommands

srem

public Long srem(String key,
                 String... members)
Specified by:
srem in interface JedisCommands

spop

public String spop(String key)
Specified by:
spop in interface JedisCommands

scard

public Long scard(String key)
Specified by:
scard in interface JedisCommands

sismember

public Boolean sismember(String key,
                         String member)
Specified by:
sismember in interface JedisCommands

srandmember

public String srandmember(String key)
Specified by:
srandmember in interface JedisCommands

zadd

public Long zadd(String key,
                 double score,
                 String member)
Specified by:
zadd in interface JedisCommands

zadd

public Long zadd(String key,
                 Map<Double,String> scoreMembers)
Specified by:
zadd in interface JedisCommands

zrange

public Set<String> zrange(String key,
                          long start,
                          long end)
Specified by:
zrange in interface JedisCommands

zrem

public Long zrem(String key,
                 String... members)
Specified by:
zrem in interface JedisCommands

zincrby

public Double zincrby(String key,
                      double score,
                      String member)
Specified by:
zincrby in interface JedisCommands

zrank

public Long zrank(String key,
                  String member)
Specified by:
zrank in interface JedisCommands

zrevrank

public Long zrevrank(String key,
                     String member)
Specified by:
zrevrank in interface JedisCommands

zrevrange

public Set<String> zrevrange(String key,
                             long start,
                             long end)
Specified by:
zrevrange in interface JedisCommands

zrangeWithScores

public Set<Tuple> zrangeWithScores(String key,
                                   long start,
                                   long end)
Specified by:
zrangeWithScores in interface JedisCommands

zrevrangeWithScores

public Set<Tuple> zrevrangeWithScores(String key,
                                      long start,
                                      long end)
Specified by:
zrevrangeWithScores in interface JedisCommands

zcard

public Long zcard(String key)
Specified by:
zcard in interface JedisCommands

zscore

public Double zscore(String key,
                     String member)
Specified by:
zscore in interface JedisCommands

sort

public List<String> sort(String key)
Specified by:
sort in interface JedisCommands

sort

public List<String> sort(String key,
                         SortingParams sortingParameters)
Specified by:
sort in interface JedisCommands

zcount

public Long zcount(String key,
                   double min,
                   double max)
Specified by:
zcount in interface JedisCommands

zcount

public Long zcount(String key,
                   String min,
                   String max)
Specified by:
zcount in interface JedisCommands

zrangeByScore

public Set<String> zrangeByScore(String key,
                                 double min,
                                 double max)
Specified by:
zrangeByScore in interface JedisCommands

zrevrangeByScore

public Set<String> zrevrangeByScore(String key,
                                    double max,
                                    double min)
Specified by:
zrevrangeByScore in interface JedisCommands

zrangeByScore

public Set<String> zrangeByScore(String key,
                                 double min,
                                 double max,
                                 int offset,
                                 int count)
Specified by:
zrangeByScore in interface JedisCommands

zrevrangeByScore

public Set<String> zrevrangeByScore(String key,
                                    double max,
                                    double min,
                                    int offset,
                                    int count)
Specified by:
zrevrangeByScore in interface JedisCommands

zrangeByScoreWithScores

public Set<Tuple> zrangeByScoreWithScores(String key,
                                          double min,
                                          double max)
Specified by:
zrangeByScoreWithScores in interface JedisCommands

zrevrangeByScoreWithScores

public Set<Tuple> zrevrangeByScoreWithScores(String key,
                                             double max,
                                             double min)
Specified by:
zrevrangeByScoreWithScores in interface JedisCommands

zrangeByScoreWithScores

public Set<Tuple> zrangeByScoreWithScores(String key,
                                          double min,
                                          double max,
                                          int offset,
                                          int count)
Specified by:
zrangeByScoreWithScores in interface JedisCommands

zrevrangeByScoreWithScores

public Set<Tuple> zrevrangeByScoreWithScores(String key,
                                             double max,
                                             double min,
                                             int offset,
                                             int count)
Specified by:
zrevrangeByScoreWithScores in interface JedisCommands

zrangeByScore

public Set<String> zrangeByScore(String key,
                                 String min,
                                 String max)
Specified by:
zrangeByScore in interface JedisCommands

zrevrangeByScore

public Set<String> zrevrangeByScore(String key,
                                    String max,
                                    String min)
Specified by:
zrevrangeByScore in interface JedisCommands

zrangeByScore

public Set<String> zrangeByScore(String key,
                                 String min,
                                 String max,
                                 int offset,
                                 int count)
Specified by:
zrangeByScore in interface JedisCommands

zrevrangeByScore

public Set<String> zrevrangeByScore(String key,
                                    String max,
                                    String min,
                                    int offset,
                                    int count)
Specified by:
zrevrangeByScore in interface JedisCommands

zrangeByScoreWithScores

public Set<Tuple> zrangeByScoreWithScores(String key,
                                          String min,
                                          String max)
Specified by:
zrangeByScoreWithScores in interface JedisCommands

zrevrangeByScoreWithScores

public Set<Tuple> zrevrangeByScoreWithScores(String key,
                                             String max,
                                             String min)
Specified by:
zrevrangeByScoreWithScores in interface JedisCommands

zrangeByScoreWithScores

public Set<Tuple> zrangeByScoreWithScores(String key,
                                          String min,
                                          String max,
                                          int offset,
                                          int count)
Specified by:
zrangeByScoreWithScores in interface JedisCommands

zrevrangeByScoreWithScores

public Set<Tuple> zrevrangeByScoreWithScores(String key,
                                             String max,
                                             String min,
                                             int offset,
                                             int count)
Specified by:
zrevrangeByScoreWithScores in interface JedisCommands

zremrangeByRank

public Long zremrangeByRank(String key,
                            long start,
                            long end)
Specified by:
zremrangeByRank in interface JedisCommands

zremrangeByScore

public Long zremrangeByScore(String key,
                             double start,
                             double end)
Specified by:
zremrangeByScore in interface JedisCommands

zremrangeByScore

public Long zremrangeByScore(String key,
                             String start,
                             String end)
Specified by:
zremrangeByScore in interface JedisCommands

linsert

public Long linsert(String key,
                    BinaryClient.LIST_POSITION where,
                    String pivot,
                    String value)
Specified by:
linsert in interface JedisCommands


Copyright © 2012. All Rights Reserved.