public class InterceptorInvoker
extends java.lang.Object
implements java.io.Serializable
| Modifier and Type | Class and Description |
|---|---|
static class |
InterceptorInvoker.CglibMethodInvoker
Calls the object's method using Cglib.
|
| Constructor and Description |
|---|
InterceptorInvoker() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
getContext(java.lang.String key)
Returns the context associated with the provided key
or null if the key is not found.
|
java.lang.Object |
invoke(java.lang.Object proxyObj,
java.lang.reflect.Method proxyMethod,
java.lang.Object targetObj,
java.lang.reflect.Method targetMethod,
java.lang.Object[] paramVals)
Calls AspectSystem to find the interceptors for the given invokedMethod and
targetMethod, creates the
invocationContext and proceeds to calling the first interceptor.
|
void |
setContext(java.lang.String key,
java.lang.Object data)
Sets the custom context.
|
public java.lang.Object invoke(java.lang.Object proxyObj,
java.lang.reflect.Method proxyMethod,
java.lang.Object targetObj,
java.lang.reflect.Method targetMethod,
java.lang.Object[] paramVals)
throws java.lang.Exception
proxyObj - dynamic proxy or the object enhanced by CGLIB.proxyMethod - method invoked by the client on the proxy. Normally, this is an interface method
(the declaring class is the interface).targetObj - object to call, e.g., EJB implementation objecttargetMethod - method to call on the target object, e.g., method of the EJB implementation clsessparamVals - method parametersjava.lang.Exceptionpublic void setContext(java.lang.String key,
java.lang.Object data)
key - key for this context's datadata - context datapublic java.lang.Object getContext(java.lang.String key)
key - context key