I - The intercepted method invocationA - The type of annotation this context information is for. One of CacheResult,
CachePut, CacheRemove, or
CacheRemoveAll.public abstract class AbstractInternalCacheInvocationContext<I,A extends Annotation> extends Object implements InternalCacheInvocationContext<A>
NOTE: This class uses arrays instead of immutable collections due to the frequency of these objects being created. In testing creating new arrays and cloning them requires less CPU time and fewer objects than creating new immutable Lists.
| Constructor and Description |
|---|
AbstractInternalCacheInvocationContext(StaticCacheInvocationContext<A> staticCacheInvocationContext,
I invocation)
Create a AbstractInternalCacheInvocationContext
|
| Modifier and Type | Method and Description |
|---|---|
javax.cache.annotation.CacheInvocationParameter[] |
getAllParameters() |
Set<Annotation> |
getAnnotations() |
A |
getCacheAnnotation() |
String |
getCacheName() |
Method |
getMethod() |
protected abstract Method |
getMethod(I invocation) |
protected abstract Object[] |
getParameters(I invocation) |
StaticCacheInvocationContext<A> |
getStaticCacheInvocationContext() |
Object |
getTarget() |
protected abstract Object |
getTarget(I invocation) |
<T> T |
unwrap(Class<T> cls) |
public AbstractInternalCacheInvocationContext(StaticCacheInvocationContext<A> staticCacheInvocationContext, I invocation)
staticCacheInvocationContext - The pre-processed method details datainvocation - The current invocation contextprotected abstract Object[] getParameters(I invocation)
invocation - The intercepted method invocationprotected abstract Method getMethod(I invocation)
invocation - The intercepted method invocationprotected abstract Object getTarget(I invocation)
invocation - The intercepted method invocationpublic StaticCacheInvocationContext<A> getStaticCacheInvocationContext()
getStaticCacheInvocationContext in interface InternalCacheInvocationContext<A extends Annotation>public Set<Annotation> getAnnotations()
getAnnotations in interface javax.cache.annotation.CacheMethodDetails<A extends Annotation>public A getCacheAnnotation()
getCacheAnnotation in interface javax.cache.annotation.CacheMethodDetails<A extends Annotation>public String getCacheName()
getCacheName in interface javax.cache.annotation.CacheMethodDetails<A extends Annotation>public Method getMethod()
getMethod in interface javax.cache.annotation.CacheMethodDetails<A extends Annotation>public Object getTarget()
getTarget in interface javax.cache.annotation.CacheInvocationContext<A extends Annotation>public javax.cache.annotation.CacheInvocationParameter[] getAllParameters()
getAllParameters in interface javax.cache.annotation.CacheInvocationContext<A extends Annotation>public <T> T unwrap(Class<T> cls)
unwrap in interface javax.cache.annotation.CacheInvocationContext<A extends Annotation>Copyright © 2019. All rights reserved.