类 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.- 从以下版本开始:
- 1.3.0
嵌套类概要
嵌套类 修饰符和类型 类 说明 static class
CacheProperties.Caffeine
Caffeine specific cache properties.static class
CacheProperties.Couchbase
Couchbase specific cache properties.static class
CacheProperties.EhCache
EhCache specific cache properties.static class
CacheProperties.Infinispan
Infinispan specific cache properties.static class
CacheProperties.JCache
JCache (JSR-107) specific cache properties.static class
CacheProperties.Redis
Redis-specific cache properties.
构造器概要
构造器 构造器 说明 CacheProperties()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 List<String>
getCacheNames()
CacheProperties.Caffeine
getCaffeine()
CacheProperties.Couchbase
getCouchbase()
CacheProperties.EhCache
getEhcache()
CacheProperties.Infinispan
getInfinispan()
CacheProperties.JCache
getJcache()
CacheProperties.Redis
getRedis()
CacheType
getType()
org.springframework.core.io.Resource
resolveConfigLocation(org.springframework.core.io.Resource config)
Resolve the config location if set.void
setCacheNames(List<String> cacheNames)
void
setType(CacheType mode)
构造器详细资料
CacheProperties
public CacheProperties()
方法详细资料
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()
getInfinispan
public CacheProperties.Infinispan getInfinispan()
getJcache
public CacheProperties.JCache getJcache()
getRedis
public CacheProperties.Redis getRedis()
resolveConfigLocation
public org.springframework.core.io.Resource resolveConfigLocation(org.springframework.core.io.Resource config)
Resolve the config location if set.- 参数:
config
- the config resource- 返回:
- the location or
null
if it is not set - 抛出:
IllegalArgumentException
- if the config attribute is set to an unknown location