org.springframework.cache.jcache.interceptor

Class AnnotationJCacheOperationSource

    • Constructor Detail

      • AnnotationJCacheOperationSource

        public AnnotationJCacheOperationSource()
    • Method Detail

      • getCacheDefaults

        @Nullable
        protected javax.cache.annotation.CacheDefaults getCacheDefaults(java.lang.reflect.Method method,
                                                                                  @Nullable
                                                                                  java.lang.Class<?> targetType)
      • createCacheResultOperation

        protected org.springframework.cache.jcache.interceptor.CacheResultOperation createCacheResultOperation(java.lang.reflect.Method method,
                                                                                                               @Nullable
                                                                                                               javax.cache.annotation.CacheDefaults defaults,
                                                                                                               javax.cache.annotation.CacheResult ann)
      • createCachePutOperation

        protected org.springframework.cache.jcache.interceptor.CachePutOperation createCachePutOperation(java.lang.reflect.Method method,
                                                                                                         @Nullable
                                                                                                         javax.cache.annotation.CacheDefaults defaults,
                                                                                                         javax.cache.annotation.CachePut ann)
      • createCacheRemoveOperation

        protected org.springframework.cache.jcache.interceptor.CacheRemoveOperation createCacheRemoveOperation(java.lang.reflect.Method method,
                                                                                                               @Nullable
                                                                                                               javax.cache.annotation.CacheDefaults defaults,
                                                                                                               javax.cache.annotation.CacheRemove ann)
      • createCacheRemoveAllOperation

        protected org.springframework.cache.jcache.interceptor.CacheRemoveAllOperation createCacheRemoveAllOperation(java.lang.reflect.Method method,
                                                                                                                     @Nullable
                                                                                                                     javax.cache.annotation.CacheDefaults defaults,
                                                                                                                     javax.cache.annotation.CacheRemoveAll ann)
      • getCacheResolver

        protected CacheResolver getCacheResolver(@Nullable
                                                 javax.cache.annotation.CacheResolverFactory factory,
                                                 javax.cache.annotation.CacheMethodDetails<?> details)
      • getExceptionCacheResolver

        protected CacheResolver getExceptionCacheResolver(@Nullable
                                                          javax.cache.annotation.CacheResolverFactory factory,
                                                          javax.cache.annotation.CacheMethodDetails<javax.cache.annotation.CacheResult> details)
      • determineCacheResolverFactory

        @Nullable
        protected javax.cache.annotation.CacheResolverFactory determineCacheResolverFactory(@Nullable
                                                                                                      javax.cache.annotation.CacheDefaults defaults,
                                                                                                      java.lang.Class<? extends javax.cache.annotation.CacheResolverFactory> candidate)
      • determineKeyGenerator

        protected KeyGenerator determineKeyGenerator(@Nullable
                                                     javax.cache.annotation.CacheDefaults defaults,
                                                     java.lang.Class<? extends javax.cache.annotation.CacheKeyGenerator> candidate)
      • determineCacheName

        protected java.lang.String determineCacheName(java.lang.reflect.Method method,
                                                      @Nullable
                                                      javax.cache.annotation.CacheDefaults defaults,
                                                      java.lang.String candidate)
      • generateDefaultCacheName

        protected java.lang.String generateDefaultCacheName(java.lang.reflect.Method method)
        Generate a default cache name for the specified Method.
        Parameters:
        method - the annotated method
        Returns:
        the default cache name, according to JSR-107
      • getBean

        protected abstract <T> T getBean(java.lang.Class<T> type)
        Locate or create an instance of the specified cache strategy type.
        Parameters:
        type - the type of the bean to manage
        Returns:
        the required bean
      • getDefaultCacheResolver

        protected abstract CacheResolver getDefaultCacheResolver()
        Return the default CacheResolver if none is set.
      • getDefaultExceptionCacheResolver

        protected abstract CacheResolver getDefaultExceptionCacheResolver()
        Return the default exception CacheResolver if none is set.
      • getDefaultKeyGenerator

        protected abstract KeyGenerator getDefaultKeyGenerator()
        Return the default KeyGenerator if none is set.