org.beangle.cache.redis.RedisCache
See theRedisCache companion object
class RedisCache[K, V](name: String, pool: JedisPool, serializer: BinarySerializer, ktype: Class[K], vtype: Class[V], val ttl: Long) extends Cache[K, V]
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Cache[K, V]class Objecttrait Matchableclass Any
Members list
Value members
Concrete methods
Remove all mappings from the cache.
Remove all mappings from the cache.
Attributes
- Definition Classes
-
Cache
Evict specified key
Evict specified key
Attributes
- Definition Classes
-
Cache
Exists key
Exists key
Attributes
- Definition Classes
-
Cache
Get Some(T) or None
Get Some(T) or None
Attributes
- Definition Classes
-
Cache
Put a new Value
Put a new Value
Attributes
- Definition Classes
-
Cache
Same with put,but return true when absent
Same with put,but return true when absent
Attributes
- Definition Classes
-
Cache
return Some(v) when exists old value
return Some(v) when exists old value
Attributes
return true is (k,oldvalue) exists
return true is (k,oldvalue) exists
Attributes
Touch the key,restart ttl The default implementation is equivalent to
Touch the key,restart ttl The default implementation is equivalent to
val v = cache.get(k)
if(v.isEmpty) false
else {
cache.remove(k)
cache.put(k,v.get)
true
}
Attributes
- Returns
-
false if key not exists
- Definition Classes
-
Cache
Time to idle seconds,-1 is forever
Time to idle seconds,-1 is forever
Attributes
- Definition Classes
-
Cache
Concrete fields
Time to live seconds,-1 is forever
Time to live seconds,-1 is forever
Attributes
In this article