Package org.infinispan.jcache.annotation
Class CacheRemoveEntryInterceptor
- java.lang.Object
-
- org.infinispan.jcache.annotation.AbstractCacheRemoveEntryInterceptor
-
- org.infinispan.jcache.annotation.CacheRemoveEntryInterceptor
-
- All Implemented Interfaces:
Serializable
@Interceptor public class CacheRemoveEntryInterceptor extends AbstractCacheRemoveEntryInterceptor
CacheRemoveinterceptor implementation.This interceptor uses the following algorithm describes in JSR-107.The interceptor that intercepts method annotated with
@CacheRemoveEntrymust do the following, generate a key based on InvocationContext using the specifiedCacheKeyGenerator, use this key to remove the entry in the cache. The remove occurs after the method body is executed. This can be overridden by specifying a afterInvocation attribute value of false. If afterInvocation is true and the annotated method throws an exception the remove will not happen.- Author:
- Kevin Pollet <kevin.pollet@serli.com> (C) 2011 SERLI, Galder ZamarreƱo
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CacheRemoveEntryInterceptor(DefaultCacheResolver cacheResolver, CacheKeyInvocationContextFactory contextFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectcacheRemoveEntry(javax.interceptor.InvocationContext invocationContext)protected org.infinispan.jcache.logging.LoggetLog()
-
-
-
Constructor Detail
-
CacheRemoveEntryInterceptor
@Inject public CacheRemoveEntryInterceptor(DefaultCacheResolver cacheResolver, CacheKeyInvocationContextFactory contextFactory)
-
-
Method Detail
-
cacheRemoveEntry
public Object cacheRemoveEntry(javax.interceptor.InvocationContext invocationContext) throws Exception
- Overrides:
cacheRemoveEntryin classAbstractCacheRemoveEntryInterceptor- Throws:
Exception
-
getLog
protected org.infinispan.jcache.logging.Log getLog()
- Specified by:
getLogin classAbstractCacheRemoveEntryInterceptor
-
-