|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.zkoss.lang.reflect.SerializableMethod org.zkoss.xel.util.MethodFunction
public class MethodFunction
A XEL function based on java.lang.reflect.Method.
It is used by implementation of ExpressionFactory
The user of XEL expressions rarely need it.
Constructor Summary | |
---|---|
MethodFunction(java.lang.reflect.Method method)
|
Method Summary | |
---|---|
java.lang.Class<?>[] |
getParameterTypes()
Returns an array of Class objects that represent the formal parameter types, in declaration order, of the method represented by this Method object. |
java.lang.Class<?> |
getReturnType()
Returns a Class object that represents the formal return type of the method represented by this Method object. |
java.lang.Object |
invoke(java.lang.Object obj,
java.lang.Object... args)
Invokes this method with the specified arguments. |
java.lang.reflect.Method |
toMethod()
Converts this function to a method, or null if unable to convert. |
Methods inherited from class org.zkoss.lang.reflect.SerializableMethod |
---|
clone, equals, getMethod, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public MethodFunction(java.lang.reflect.Method method)
Method Detail |
---|
public java.lang.Class<?>[] getParameterTypes()
Function
Returns an array of length 0 if the underlying method takes no parameters.
getParameterTypes
in interface Function
public java.lang.Class<?> getReturnType()
Function
getReturnType
in interface Function
public java.lang.Object invoke(java.lang.Object obj, java.lang.Object... args) throws java.lang.Exception
Function
invoke
in interface Function
obj
- the object the underlying method is invoked from.
It is always null if this function is invoked in an XEL expression.
It is reserved for more sophisticated expressions, such as
ZK Spreadsheet's expressions.args
- the arguments used for the method call.
If null, an Object array with zero length is assumed.
java.lang.Exception
public java.lang.reflect.Method toMethod()
Function
toMethod
in interface Function
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |