|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.sdm.quasar.client.core.commands.RunnableCommandManager
com.sdm.quasar.client.core.commands.GenericCommandManager
A generic implementation of CommandManager, that can call any
public method (by reflection). The enablement state must be provided by
the user of this class.
| Constructor Summary | |
GenericCommandManager()
Creates a new GenericCommandManager. |
|
| Method Summary | |
void |
registerCommand(java.lang.String commandId,
java.lang.Object target,
java.lang.Class targetClass,
java.lang.String methodName,
BooleanState enabledBooleanState)
Registers a new command with the given id and parameters to this GenericCommandManager. |
void |
registerCommand(java.lang.String commandId,
java.lang.Object target,
java.lang.reflect.Method method,
BooleanState enabledBooleanState)
Registers a new command with the given id and parameters to this GenericCommandManager. |
void |
registerCommand(java.lang.String name,
java.lang.Object target,
java.lang.String methodName,
BooleanState enabledBooleanState)
Registers a new command with the given id and parameters to this GenericCommandManager. |
| Methods inherited from class com.sdm.quasar.client.core.commands.RunnableCommandManager |
getCommand, hasCommand, registerCommand, setEnabledBooleanState, unregisterCommand |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public GenericCommandManager()
GenericCommandManager.
| Method Detail |
public void registerCommand(java.lang.String commandId,
java.lang.Object target,
java.lang.reflect.Method method,
BooleanState enabledBooleanState)
GenericCommandManager.
commandId - the command id for the command (not null)target - the target object instance to execute a method of (may be null,
then the method to execute should be static)method - the Method beeing executed on the target object (not null)enabledBooleanState - an enabled state (may be null; this means the command
is always enabled)
java.lang.IllegalArgumentException - if command id or method is null or if
the given method cannot be executed on the given target object
public void registerCommand(java.lang.String commandId,
java.lang.Object target,
java.lang.Class targetClass,
java.lang.String methodName,
BooleanState enabledBooleanState)
GenericCommandManager.
commandId - the command id for the command (not null)target - the target object instance to execute a method of (may be null,
then the method to execute should be static)targetClass - the Class of the target object to execute a method of (not null)methodName - the name of the method beeing execute (not null, should be
a method name of the target class). The method must take no arguments.enabledBooleanState - an enabled state (may be null; this means the command
is always enabled)
public void registerCommand(java.lang.String name,
java.lang.Object target,
java.lang.String methodName,
BooleanState enabledBooleanState)
GenericCommandManager.
target - the target object instance to execute a method of (not null)methodName - the name of the method beeing execute (not null, should be
a method name of the target's class). The method must take no arguments.enabledBooleanState - an enabled state (may be null; this means the command
is always enabled)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||