public abstract class AbstractDynamicMethodsInterceptor extends AbstractDynamicMethods implements PropertyAccessInterceptor, ConstructorInterceptor
clazz, dynamicConstructors, dynamicMethodInvocations, dynamicProperties, staticMethodInvocations| Constructor and Description |
|---|
AbstractDynamicMethodsInterceptor() |
AbstractDynamicMethodsInterceptor(java.lang.Class<?> theClass) |
AbstractDynamicMethodsInterceptor(java.lang.Class<?> theClass,
boolean inRegistry) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
afterConstructor(java.lang.Object[] args,
java.lang.Object instantiatedInstance)
Executed after the constructor passing the args and the instantiated instance.
|
java.lang.Object |
afterInvoke(java.lang.Object object,
java.lang.String methodName,
java.lang.Object[] arguments,
java.lang.Object result)
This code is executed after the method is optionally called.
|
java.lang.Object |
beforeConstructor(java.lang.Object[] args,
InvocationCallback callback)
Executed before the real constructor.
|
java.lang.Object |
beforeGet(java.lang.Object object,
java.lang.String property,
InvocationCallback callback)
Intercepts a getXXX call and returns a result.
|
java.lang.Object |
beforeInvoke(java.lang.Object target,
java.lang.String methodName,
java.lang.Object[] arguments,
InvocationCallback callback)
This code is executed before the method is optionally called.
|
void |
beforeSet(java.lang.Object object,
java.lang.String property,
java.lang.Object newValue,
InvocationCallback callback)
Intercepts a setXXX call.
|
addDynamicConstructor, addDynamicMethodInvocation, addDynamicProperty, addStaticMethodInvocation, getDynamicMethod, getDynamicProperty, getProperty, invokeConstructor, invokeMethod, invokeStaticMethod, setPropertypublic AbstractDynamicMethodsInterceptor()
public AbstractDynamicMethodsInterceptor(java.lang.Class<?> theClass,
boolean inRegistry)
public AbstractDynamicMethodsInterceptor(java.lang.Class<?> theClass)
public java.lang.Object afterConstructor(java.lang.Object[] args,
java.lang.Object instantiatedInstance)
ConstructorInterceptorafterConstructor in interface ConstructorInterceptorargs - The argumentsinstantiatedInstance - The instantiated instancepublic java.lang.Object beforeConstructor(java.lang.Object[] args,
InvocationCallback callback)
ConstructorInterceptorbeforeConstructor in interface ConstructorInterceptorargs - The constructor argscallback - The callback objectpublic java.lang.Object beforeInvoke(java.lang.Object target,
java.lang.String methodName,
java.lang.Object[] arguments,
InvocationCallback callback)
InterceptorbeforeInvoke in interface Interceptortarget - receiver object for the method callmethodName - name of the method to callarguments - arguments to the method callcallback - The callback objectpublic java.lang.Object afterInvoke(java.lang.Object object,
java.lang.String methodName,
java.lang.Object[] arguments,
java.lang.Object result)
InterceptorafterInvoke in interface Interceptorobject - receiver object for the called methodmethodName - name of the called methodarguments - arguments to the called methodresult - result of the executed method call or result of beforeInvoke if method was not calledpublic java.lang.Object beforeGet(java.lang.Object object,
java.lang.String property,
InvocationCallback callback)
PropertyAccessInterceptorbeforeGet in interface PropertyAccessInterceptorobject - The target objectproperty - The property to getcallback - The callback objectpublic void beforeSet(java.lang.Object object,
java.lang.String property,
java.lang.Object newValue,
InvocationCallback callback)
PropertyAccessInterceptorbeforeSet in interface PropertyAccessInterceptorobject - The target objectproperty - The property to setnewValue - The new valuecallback - The callback object