rename exists to hasKey()

This commit is contained in:
Costin Leau
2010-12-08 22:55:54 +02:00
parent b7dcfb67a1
commit 48b9df3a05
2 changed files with 2 additions and 2 deletions

View File

@@ -50,7 +50,7 @@ public interface RedisOperations<K, V> {
*/
<T> T execute(RedisCallback<T> action);
Boolean exists(K key);
Boolean hasKey(K key);
void delete(Collection<K> key);

View File

@@ -407,7 +407,7 @@ public class RedisTemplate<K, V> extends RedisAccessor implements RedisOperation
}
@Override
public Boolean exists(K key) {
public Boolean hasKey(K key) {
final byte[] rawKey = rawKey(key);
return execute(new RedisCallback<Boolean>() {