|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectubiware.core.commands.BlockingCommand<E>
public class BlockingCommand<E>
Implementation of a command that has an extra method waitForExecution() which only returns once the command has
been executed.
15.3.2010
| Constructor Summary | |
|---|---|
BlockingCommand(UbiwareAgentCommand<E> command)
Create the command with the wrapped command. |
|
| Method Summary | |
|---|---|
E |
getResult()
Get the result of the action performed. |
void |
performCommand(UbiwareAgent agent)
The code which will get executed by the agent. |
E |
waitForExecution()
This method only returns once the wrapped command has been executed It returns the same value as getResult returns after this call has been made. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BlockingCommand(UbiwareAgentCommand<E> command)
command - The wrapped command| Method Detail |
|---|
public void performCommand(UbiwareAgent agent)
UbiwareAgentCommand
performCommand in interface UbiwareAgentCommand<E>agent - The agent which is executing the commandpublic E waitForExecution()
public E getResult()
UbiwareAgentCommandUbiwareAgentCommand.performCommand(UbiwareAgent) has not been executed, the behavior of this
method is undefined.
getResult in interface UbiwareAgentCommand<E>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||