org.logicalcobwebs.proxool.proxy
public class MethodMapper extends java.lang.Object
Constructor and Description |
---|
MethodMapper(java.lang.Class concreteClass) |
Modifier and Type | Method and Description |
---|---|
protected java.lang.reflect.Method |
getConcreteMethod(java.lang.reflect.Method injectableMethod)
Returns the method in the concrete class with an indentical signature to that passed
as a parameter
|
void |
overrideConcreteMethod(java.lang.reflect.Method injectableMethod,
java.lang.reflect.Method overridenMethod)
Don't use the one we calculate using
getConcreteMethod(java.lang.reflect.Method) , use this one instead. |
public MethodMapper(java.lang.Class concreteClass)
concreteClass
- the class that we want to invoke methods on. It should either implement all methods on
the injectable interface, or provide methods with an identical signature.protected java.lang.reflect.Method getConcreteMethod(java.lang.reflect.Method injectableMethod) throws ProxoolException
injectableMethod
- provides signature that we are trying to matchProxoolException
- if the method is not found.public void overrideConcreteMethod(java.lang.reflect.Method injectableMethod, java.lang.reflect.Method overridenMethod)
getConcreteMethod(java.lang.reflect.Method)
, use this one instead.injectableMethod
- the method supplied by the proxyoverridenMethod
- the one we are going to use (probably the same as injectrableMethod actually)