|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.AbstractCollection<E>
org.springframework.data.redis.support.collections.AbstractRedisCollection<E>
public abstract class AbstractRedisCollection<E>
Base implementation for RedisCollection. Provides a skeletal implementation. Note that the collection support
works only with normal, non-pipeline/multi-exec connections as it requires a reply to be sent right away.
| Field Summary | |
|---|---|
static String |
ENCODING
|
| Constructor Summary | |
|---|---|
AbstractRedisCollection(String key,
RedisOperations<String,E> operations)
|
|
| Method Summary | |
|---|---|
abstract boolean |
add(E e)
|
boolean |
addAll(Collection<? extends E> c)
|
protected void |
checkResult(Object obj)
|
abstract void |
clear()
|
boolean |
containsAll(Collection<?> c)
|
boolean |
equals(Object o)
|
Boolean |
expire(long timeout,
TimeUnit unit)
Sets the key time-to-live/expiration. |
Boolean |
expireAt(Date date)
Sets the key time-to-live/expiration. |
Long |
getExpire()
Returns the expiration of this key. |
String |
getKey()
Returns the key associated with this entity. |
RedisOperations<String,E> |
getOperations()
Returns the underlying Redis operations used by the backing implementation. |
int |
hashCode()
|
Boolean |
persist()
Removes the expiration (if any) of the key. |
abstract boolean |
remove(Object o)
|
boolean |
removeAll(Collection<?> c)
|
void |
rename(String newKey)
Renames the key. |
String |
toString()
|
| Methods inherited from class java.util.AbstractCollection |
|---|
contains, isEmpty, iterator, retainAll, size, toArray, toArray |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.springframework.data.redis.core.BoundKeyOperations |
|---|
getType |
| Field Detail |
|---|
public static final String ENCODING
| Constructor Detail |
|---|
public AbstractRedisCollection(String key,
RedisOperations<String,E> operations)
| Method Detail |
|---|
public String getKey()
BoundKeyOperations
getKey in interface BoundKeyOperations<String>public RedisOperations<String,E> getOperations()
RedisStore
getOperations in interface RedisStorepublic boolean addAll(Collection<? extends E> c)
addAll in interface Collection<E>addAll in class AbstractCollection<E>public abstract boolean add(E e)
add in interface Collection<E>add in class AbstractCollection<E>public abstract void clear()
clear in interface Collection<E>clear in class AbstractCollection<E>public boolean containsAll(Collection<?> c)
containsAll in interface Collection<E>containsAll in class AbstractCollection<E>public abstract boolean remove(Object o)
remove in interface Collection<E>remove in class AbstractCollection<E>public boolean removeAll(Collection<?> c)
removeAll in interface Collection<E>removeAll in class AbstractCollection<E>public boolean equals(Object o)
equals in interface Collection<E>equals in class Objectpublic int hashCode()
hashCode in interface Collection<E>hashCode in class Objectpublic String toString()
toString in class AbstractCollection<E>
public Boolean expire(long timeout,
TimeUnit unit)
BoundKeyOperations
expire in interface BoundKeyOperations<String>timeout - expiration valueunit - expiration unit
public Boolean expireAt(Date date)
BoundKeyOperations
expireAt in interface BoundKeyOperations<String>date - expiration date
public Long getExpire()
BoundKeyOperations
getExpire in interface BoundKeyOperations<String>public Boolean persist()
BoundKeyOperations
persist in interface BoundKeyOperations<String>public void rename(String newKey)
BoundKeyOperations
rename in interface BoundKeyOperations<String>newKey - new keyprotected void checkResult(Object obj)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||