Package org.springframework.cache.annotation

# Class AbstractCachingConfiguration

java.lang.Object
org.springframework.cache.annotation.AbstractCachingConfiguration

All Implemented Interfaces:
  `org.springframework.beans.factory.Aware`, `ImportAware`

Direct Known Subclasses:
  `ProxyCachingConfiguration`

@Configuration(proxyBeanMethods=false) public abstract class AbstractCachingConfiguration extends Object implements ImportAware
Abstract base `@Configuration` class providing common structure for enabling Spring's annotation-driven cache management capability.

Since:
  3.1
Author:
  Chris Beams, Stephane Nicoll, Juergen Hoeller
See Also:
  - `EnableCaching`

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`protected static class`
`AbstractCachingConfiguration.CachingConfigurerSupplier`

## Field Summary

Fields
Modifier and Type
Field
Description
`protected Supplier<CacheManager>`
`cacheManager`
`protected Supplier<CacheResolver>`
`cacheResolver`
`protected org.springframework.core.annotation.AnnotationAttributes`
`enableCaching`
`protected Supplier<CacheErrorHandler>`
`errorHandler`
`protected Supplier<KeyGenerator>`
`keyGenerator`

## Constructor Summary

Constructors
Constructor
Description
`AbstractCachingConfiguration()`

## Method Summary

Modifier and Type
Method
Description
`void`
`setImportMetadata(org.springframework.core.type.AnnotationMetadata importMetadata)`
Set the annotation metadata of the importing @`Configuration` class.
`protected void`
`useCachingConfigurer(AbstractCachingConfiguration.CachingConfigurerSupplier cachingConfigurerSupplier)`
Extract the configuration from the nominated `CachingConfigurer`.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### enableCaching

@Nullable protected org.springframework.core.annotation.AnnotationAttributes enableCaching

### cacheManager

@Nullable protected Supplier<CacheManager> cacheManager

### cacheResolver

@Nullable protected Supplier<CacheResolver> cacheResolver

### keyGenerator

@Nullable protected Supplier<KeyGenerator> keyGenerator

### errorHandler

@Nullable protected Supplier<CacheErrorHandler> errorHandler

## Constructor Details

### AbstractCachingConfiguration

public AbstractCachingConfiguration()

## Method Details

### setImportMetadata

public void setImportMetadata(org.springframework.core.type.AnnotationMetadata importMetadata)
Description copied from interface: `ImportAware`
Set the annotation metadata of the importing @`Configuration` class.

Specified by:
  `setImportMetadata` in interface `ImportAware`

### useCachingConfigurer

protected void useCachingConfigurer(AbstractCachingConfiguration.CachingConfigurerSupplier cachingConfigurerSupplier)
Extract the configuration from the nominated `CachingConfigurer`.