Class MethodUtils
java.lang.Object
org.chenile.core.util.MethodUtils
Given an OperationDefinition and a service class, this class computes the java.lang.reflect.Method.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic MethodcomputeMethod(Class<?> clazz, OperationDefinition od) Note that this uses theParamDefinition.getParamClass()to compute the method.
-
Constructor Details
-
MethodUtils
public MethodUtils()
-
-
Method Details
-
computeMethod
Note that this uses theParamDefinition.getParamClass()to compute the method. This is because the param class will return the definition of the request body in the actual class and not in the context of the instance. for example consider the following code:public class A{ public void consumer(T t){} } public class Bar extends Foo{} - Parameters:
clazz- - the class whose method we need to computeod- - the operation definition that defines the method's name and other details- Returns:
- - the method that needs to be invoked. Null if the method is not found.
-