Package net.n2oapp.cache.template
Class TwoLevelCacheTemplate<K,F,S>
- java.lang.Object
-
- net.n2oapp.cache.template.TwoLevelCacheTemplate<K,F,S>
-
- Direct Known Subclasses:
SyncTwoLevelCacheTemplate
public class TwoLevelCacheTemplate<K,F,S> extends Object
Шаблон сервиса двухуровневого кэширования
-
-
Constructor Summary
Constructors Constructor Description TwoLevelCacheTemplate()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Fexecute(String firstLevelRegion, String secondLevelRegion, K key, TwoLevelCacheCallback<F,S> callback)protected FhandleFirstCache(K key, TwoLevelCacheCallback<F,S> callback, org.springframework.cache.Cache firstLevelCache, S secondLevelCacheValue)protected ShandleSecondCache(K key, TwoLevelCacheCallback<F,S> callback, org.springframework.cache.Cache secondLevelCache)voidsetCacheManager(org.springframework.cache.CacheManager cacheManager)
-
-
-
Method Detail
-
setCacheManager
public void setCacheManager(org.springframework.cache.CacheManager cacheManager)
-
execute
public F execute(String firstLevelRegion, String secondLevelRegion, K key, TwoLevelCacheCallback<F,S> callback)
-
handleFirstCache
protected F handleFirstCache(K key, TwoLevelCacheCallback<F,S> callback, org.springframework.cache.Cache firstLevelCache, S secondLevelCacheValue)
-
handleSecondCache
protected S handleSecondCache(K key, TwoLevelCacheCallback<F,S> callback, org.springframework.cache.Cache secondLevelCache)
-
-