Package com.oracle.coherence.cdi
Class CacheAddInterceptor
- java.lang.Object
-
- com.oracle.coherence.cdi.AbstractCacheInterceptor
-
- com.oracle.coherence.cdi.CacheAddInterceptor
-
@Interceptor @Priority(1005) public class CacheAddInterceptor extends AbstractCacheInterceptor
A CDI interceptor that always invokes target method and then caches invocation result before returning it.
-
-
Constructor Summary
Constructors Constructor Description CacheAddInterceptor(Coherence coherence, CoherenceExtension extension)
Create theCacheAddInterceptor
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
cacheAdd(javax.interceptor.InvocationContext ctxInvocation)
Always invokes target method and caches invocation result before returning it.-
Methods inherited from class com.oracle.coherence.cdi.AbstractCacheInterceptor
getCoherence, getExtension, getSession
-
-
-
-
Constructor Detail
-
CacheAddInterceptor
@Inject public CacheAddInterceptor(@Name("") Coherence coherence, CoherenceExtension extension)
Create theCacheAddInterceptor
.- Parameters:
coherence
- the Coherence instanceextension
- the Coherence CDI extension
-
-
Method Detail
-
cacheAdd
public Object cacheAdd(javax.interceptor.InvocationContext ctxInvocation) throws Exception
Always invokes target method and caches invocation result before returning it.- Parameters:
ctxInvocation
- the invocation context- Returns:
- a result of the invocation of the target method
- Throws:
Exception
- if thrown by target method
-
-