public class MethodExecutionAction extends java.lang.Object implements CommandAction
Method.invoke(Object, Object...) throws exception then this exception is wrapped to CommandActionExecutionException
for further unwrapping and processing.| Constructor and Description |
|---|
MethodExecutionAction(java.lang.Object object,
java.lang.reflect.Method method,
MetaHolder metaHolder) |
MethodExecutionAction(java.lang.Object object,
java.lang.reflect.Method method,
java.lang.Object[] args,
MetaHolder metaHolder) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
execute(ExecutionType executionType)
Executes action in accordance with the given execution type.
|
java.lang.Object |
executeWithArgs(ExecutionType executionType,
java.lang.Object[] args)
Invokes the method.
|
java.lang.String |
getActionName()
Gets action name.
|
java.lang.Object[] |
getArgs() |
MetaHolder |
getMetaHolder() |
java.lang.reflect.Method |
getMethod() |
java.lang.Object |
getObject() |
public MethodExecutionAction(java.lang.Object object,
java.lang.reflect.Method method,
MetaHolder metaHolder)
public MethodExecutionAction(java.lang.Object object,
java.lang.reflect.Method method,
java.lang.Object[] args,
MetaHolder metaHolder)
public java.lang.Object getObject()
public java.lang.reflect.Method getMethod()
public java.lang.Object[] getArgs()
public MetaHolder getMetaHolder()
getMetaHolder in interface CommandActionpublic java.lang.Object execute(ExecutionType executionType) throws CommandActionExecutionException
CommandActionexecute in interface CommandActionexecutionType - the execution typeCommandActionExecutionExceptionpublic java.lang.Object executeWithArgs(ExecutionType executionType, java.lang.Object[] args) throws CommandActionExecutionException
executeWithArgs in interface CommandActionexecutionType - the execution typeargs - the parameters of the actionCommandActionExecutionExceptionpublic java.lang.String getActionName()
getActionName in interface CommandAction