ewe.reflect
Class Method
java.lang.Object
ewe.reflect.MethodConstructor
ewe.reflect.Method
- All Implemented Interfaces:
- IMethod, Member
- public class Method
- extends MethodConstructor
This is used to invoke methods on objects. It works on static and instance methods.
invocationError
public Throwable invocationError
invoke
public Wrapper invoke(Object target,
Wrapper[] parameters,
Wrapper result)
- Invoke the method on the specified target object.
- Parameters:
target - The object to invoke the method on, or null in the case of static methods.parameters - an array of parameters which must be of the correct length.
- Returns:
- A wrapper containing the returned value. If the method type is void then the value
stored in the wrapper should be ignored. If the returned value is null then an error occured
and the invocationError variable will hold the exception that caused it.
returnsValue
public boolean returnsValue()
- Returns true if the method is not of type void.
toString
public String toString()
- Description copied from class:
Object
- Return a String representation of this object.
- Overrides:
toString in class MethodConstructor
toJavaMethod
public Method toJavaMethod()