MacroCommand
| Kind of class: | public interface |
|---|---|
| Package: | com.bourre.commands |
| Inherits from: | Command |
| Implemented by: | |
| Author: | Francis Bourre |
| Classpath: | com.bourre.commands.MacroCommand |
| File last modified: | Friday, 15 February 2008, 21:35:41 |
A macro command wraps many commands execution in a single
except if a concret implementation provide a guarantee
over the order of commands.
execute call. The MacroCommanddoesn't guarantee the order of commands to be executed,except if a concret implementation provide a guarantee
over the order of commands.
Some implementations can choose to allow more than one
instance of the same command in its commands list. In
that case the macro command should follow the rules defines
by the Collection interface about duplicate
entries.
Some implementation can stretch the execution of its sub-commands
outside of the execute call, in that case the concret
implementation had better tom also implements the ASyncCommandinterface to provide a feedback for its execution end.
See also:
- com.bourre.collection.Collection
Summary
Instance methods
- addCommand (command:Command) : Boolean
- Adds the passed-in command to this macro command.
- removeCommand (command:Command) : Boolean
- Removes the passed-in command from this macro command.
Instance methods
addCommand
Adds the passed-in command to this macro command.
Parameters:
command:
command to add in this macro command
Returns:
-
trueif the command have been
succesfully added. TheaddCommandensure that the command exist in the macro
command at the end of the call
removeCommand
Removes the passed-in command from this macro command.
Parameters:
command:
command to remove from this macro command
Returns:
-
trueif the command have been
succesfully removed