Class CacheProperties
- java.lang.Object
- org.springframework.boot.autoconfigure.cache.CacheProperties
@ConfigurationProperties(prefix="spring.cache") public class CacheProperties extends Object
Configuration properties for the cache abstraction.- Since:
- 1.3.0
Nested Class Summary
Nested Classes Modifier and Type Class Description static classCacheProperties.CaffeineCaffeine specific cache properties.static classCacheProperties.CouchbaseCouchbase specific cache properties.static classCacheProperties.EhCacheEhCache specific cache properties.static classCacheProperties.GuavaGuava specific cache properties.static classCacheProperties.HazelcastDeprecated.static classCacheProperties.InfinispanInfinispan specific cache properties.static classCacheProperties.JCacheJCache (JSR-107) specific cache properties.
Constructor Summary
Constructors Constructor Description CacheProperties()
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description List<String>getCacheNames()CacheProperties.CaffeinegetCaffeine()CacheProperties.CouchbasegetCouchbase()CacheProperties.EhCachegetEhcache()CacheProperties.GuavagetGuava()CacheProperties.HazelcastgetHazelcast()Deprecated.CacheProperties.InfinispangetInfinispan()CacheProperties.JCachegetJcache()CacheTypegetType()org.springframework.core.io.ResourceresolveConfigLocation(org.springframework.core.io.Resource config)Resolve the config location if set.voidsetCacheNames(List<String> cacheNames)voidsetType(CacheType mode)
Constructor Detail
CacheProperties
public CacheProperties()
Method Detail
getCacheNames
public List<String> getCacheNames()
setCacheNames
public void setCacheNames(List<String> cacheNames)
getCaffeine
public CacheProperties.Caffeine getCaffeine()
getCouchbase
public CacheProperties.Couchbase getCouchbase()
getEhcache
public CacheProperties.EhCache getEhcache()
getHazelcast
@Deprecated public CacheProperties.Hazelcast getHazelcast()
Deprecated.
getInfinispan
public CacheProperties.Infinispan getInfinispan()
getJcache
public CacheProperties.JCache getJcache()
getGuava
public CacheProperties.Guava getGuava()
resolveConfigLocation
public org.springframework.core.io.Resource resolveConfigLocation(org.springframework.core.io.Resource config)
Resolve the config location if set.- Parameters:
config- the config resource- Returns:
- the location or
nullif it is not set - Throws:
IllegalArgumentException- if the config attribute is set to an unknown location