public class RedisCommand extends Object
| 限定符和类型 | 类和说明 |
|---|---|
static interface |
RedisCommand.Executeable<T> |
| 构造器和说明 |
|---|
RedisCommand() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
del(byte[]... keys) |
void |
del(String... keys) |
<T> T |
executeCommand(RedisCommand.Executeable<T> exe,
Object... objects) |
Boolean |
exists(byte[] key) |
Boolean |
exists(String key) |
Boolean |
expire(byte[] key,
long seconds) |
Boolean |
expire(String key,
long seconds) |
byte[] |
get(byte[] key) |
String |
get(String key) |
byte[] |
hget(byte[] key,
byte[] field) |
String |
hget(String key,
String field) |
Map<byte[],byte[]> |
hgetAll(byte[] key) |
Map<String,String> |
hgetAll(String key) |
void |
hmset(byte[] key,
Map<byte[],byte[]> hash) |
void |
hmset(String key,
Map<String,String> hash) |
Boolean |
hset(byte[] key,
byte[] field,
byte[] value) |
Boolean |
hset(String key,
String field,
String value) |
Set<byte[]> |
keys(byte[] pattern) |
Set<String> |
keys(String pattern) |
Long |
publish(byte[] channel,
byte[] message) |
Long |
publish(String channel,
String message) |
void |
set(byte[] key,
byte[] value) |
void |
set(String key,
String value) |
void |
setex(byte[] key,
long seconds,
byte[] value) |
void |
setex(String key,
long seconds,
String value) |
Boolean |
setnx(byte[] key,
byte[] value) |
Boolean |
setnx(String key,
String value) |
void |
setRedisConnectionFactory(org.springframework.data.redis.connection.RedisConnectionFactory redisConnectionFactory) |
void |
subscribe(AbstractMessageListener listener,
String... channels) |
void |
subscribe(org.springframework.data.redis.connection.MessageListener listener,
byte[]... channels) |
void |
unsubscribe(byte[]... channels) |
void |
unsubscribe(String... channels) |
public void setRedisConnectionFactory(org.springframework.data.redis.connection.RedisConnectionFactory redisConnectionFactory)
public Long publish(byte[] channel, byte[] message)
public byte[] get(byte[] key)
public void set(byte[] key,
byte[] value)
public Boolean setnx(byte[] key, byte[] value)
public void hmset(byte[] key,
Map<byte[],byte[]> hash)
public void del(String... keys)
public void del(byte[]... keys)
public Boolean expire(byte[] key, long seconds)
public Set<byte[]> keys(byte[] pattern)
public void setex(byte[] key,
long seconds,
byte[] value)
public Boolean exists(byte[] key)
public byte[] hget(byte[] key,
byte[] field)
public Map<byte[],byte[]> hgetAll(byte[] key)
public Boolean hset(byte[] key, byte[] field, byte[] value)
public void subscribe(org.springframework.data.redis.connection.MessageListener listener,
byte[]... channels)
public void subscribe(AbstractMessageListener listener, String... channels)
public void unsubscribe(byte[]... channels)
public void unsubscribe(String... channels)
public <T> T executeCommand(RedisCommand.Executeable<T> exe, Object... objects)
Copyright © 2018. All rights reserved.