Class CoherenceCacheConfiguration
- java.lang.Object
-
- com.oracle.coherence.spring.cache.CoherenceCacheConfiguration
-
public class CoherenceCacheConfiguration extends Object
Defines additional configuration properties for theCoherenceCache
. Can also serve as default cache configuration viaCoherenceCacheManager
.- Since:
- 3.0
- Author:
- Gunnar Hillert
-
-
Constructor Summary
Constructors Constructor Description CoherenceCacheConfiguration()
CoherenceCacheConfiguration(Duration timeToLive)
Initialize the cache configuration properties.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getCacheName(String name)
String
getCacheNamePrefix()
Duration
getTimeToLive()
Returns the expiration time for cache entries.boolean
isUseCacheNamePrefix()
void
setCacheNamePrefix(String cacheNamePrefix)
void
setTimeToLive(Duration timeToLive)
void
setUseCacheNamePrefix(boolean useCacheNamePrefix)
-
-
-
Constructor Detail
-
CoherenceCacheConfiguration
public CoherenceCacheConfiguration()
-
CoherenceCacheConfiguration
public CoherenceCacheConfiguration(Duration timeToLive)
Initialize the cache configuration properties.- Parameters:
timeToLive
- the expiration time for cache entries. Set it toDuration.ZERO
to not expire entries or to control the expiration via the coherence-cache-config.xml file.
-
-
Method Detail
-
getTimeToLive
public Duration getTimeToLive()
Returns the expiration time for cache entries. Should never be null.- Returns:
- the time-to-live (TTL) for cache entries.
-
setTimeToLive
public void setTimeToLive(Duration timeToLive)
-
isUseCacheNamePrefix
public boolean isUseCacheNamePrefix()
-
setUseCacheNamePrefix
public void setUseCacheNamePrefix(boolean useCacheNamePrefix)
-
getCacheNamePrefix
public String getCacheNamePrefix()
-
setCacheNamePrefix
public void setCacheNamePrefix(String cacheNamePrefix)
-
-