Class CacheProperties

java.lang.Object
org.springframework.boot.cache.autoconfigure.CacheProperties

@ConfigurationProperties("spring.cache") public class CacheProperties extends Object
Configuration properties for the cache abstraction.
Since:
4.0.0
  • Constructor Details

    • CacheProperties

      public CacheProperties()
  • Method Details

    • getType

      public @Nullable org.springframework.boot.autoconfigure.cache.CacheType getType()
    • setType

      public void setType(@Nullable org.springframework.boot.autoconfigure.cache.CacheType mode)
    • getCacheNames

      public List<String> getCacheNames()
    • setCacheNames

      public void setCacheNames(List<String> cacheNames)
    • getCaffeine

      public CacheProperties.Caffeine getCaffeine()
    • getCouchbase

      public CacheProperties.Couchbase getCouchbase()
    • getInfinispan

      public CacheProperties.Infinispan getInfinispan()
    • getJcache

      public CacheProperties.JCache getJcache()
    • getRedis

      public CacheProperties.Redis getRedis()
    • resolveConfigLocation

      public @Nullable org.springframework.core.io.Resource resolveConfigLocation(@Nullable org.springframework.core.io.Resource config)
      Resolve the config location if set.
      Parameters:
      config - the config resource
      Returns:
      the location or null if it is not set
      Throws:
      IllegalArgumentException - if the config attribute is set to an unknown location