com.ibm.bpc.clientcore
Interface Command
- public interface Command
execute(List)
.
The command implementation must check any preconditions and the context before it performs the
execute method. If the execute method succeeds, it returns a String
to indicate the result.
The caller can use this string to determine the following actions, e.g. determine the next
view on the user interface. If the execute method fails, it throws a ClientException
.
If the command is used as a batch command, the command can report several exceptions that relate to diverent items using an
ErrorsInCommandException
.
Field Summary
Modifier and Type | Field and Description |
---|---|
|
COPYRIGHT
(C) Copyright IBM Corporation 2005.
|
Method Summary
Modifier and Type | Method and Description |
---|---|
|
execute(java.util.List selectedObjects)
Excutes the command on a list of Business Process Choregrapher application objects.
|
|
isApplicable(java.util.List itemsOnList)
Checks if the command's preconidtions are met for the list of selected objects.
|
|
isMultiSelectEnabled()
Indicates if the command is enabled for multiple selection.
|
|
setContext(java.lang.Object context)
Sets the context object for the
Command .
|
Field Detail
COPYRIGHT
- static final java.lang.String COPYRIGHT
(C) Copyright IBM Corporation 2005.
See Also:
Method Detail
execute
- java.lang.String execute(java.util.List selectedObjects)
- throws ClientException
Excutes the command on a list of Business Process Choregrapher application objects.
Parameters:
selectedObjects
- The environment must provide the list of application objects on which the Command is to be executed. Returns:
A String indicating the outcome of the command.
Throws:
isMultiSelectEnabled
- boolean isMultiSelectEnabled()
Indicates if the command is enabled for multiple selection.
Returns:
true if the command can handle multiple objects. false if the command can only handle a single object.
isApplicable
- boolean[] isApplicable(java.util.List itemsOnList)
Checks if the command's preconidtions are met for the list of selected objects.
Parameters:
itemsOnList
- The list of objects to be checked. Returns:
An array of boolean values which indicate if the
Command
is applicable to the corresponding item in the list. setContext
- void setContext(java.lang.Object context)
Sets the context object for the
Command
. A context object provides required information to the command implementation during
its execute(List)
method.
Parameters:
context
- The context object which the command implementation uses.