public abstract class InvocationStub
extends java.lang.Object
implements java.lang.reflect.InvocationHandler
invokeCore(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
method.Constructor and Description |
---|
InvocationStub() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
This method acts as an interceptor which is called every time a
method of the proxy object is invoked.
|
abstract java.lang.Object |
invokeCore(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
Core interceptor logic which is called from the main try block in the
invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[]) method. |
public java.lang.Object invoke(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args) throws java.lang.Throwable
invoke
in interface java.lang.reflect.InvocationHandler
proxy
- Proxy object upon which the intercepted method is invoked.method
- Method to be invoked through reflection.args
- Arguments, if any, to method
.java.lang.Throwable
- if an exception/error occurs upon the invocation target.public abstract java.lang.Object invokeCore(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args) throws java.lang.Throwable
invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[])
method.proxy
- Proxy object upon which the intercepted method is invoked.method
- Method to be invoked through reflection.args
- Arguments, if any, to method
.java.lang.Throwable
- if an exception/error occurs upon the invocation target,
or if any problem occurs during pre- or post-processing.