|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.nexttext.behaviour.Action.ActionResult
public static class Action.ActionResult
Used to communicate results of Action.behave().
Field Summary | |
---|---|
boolean |
canComplete
Indicate if the Action can ever complete for this object. |
boolean |
complete
Indicate that the action has completed. |
boolean |
event
Indicate that an event occured in this step. |
Constructor Summary | |
---|---|
Action.ActionResult()
Create an action result suitable for use in combine(). |
|
Action.ActionResult(boolean complete,
boolean canComplete,
boolean event)
|
Method Summary | |
---|---|
void |
combine(Action.ActionResult ar)
Combine multiple ActionResults into a single one. |
Action.ActionResult |
endCombine()
Ends the combining of several ActionResults, so it can be returned. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public boolean complete
public boolean canComplete
public boolean event
Constructor Detail |
---|
public Action.ActionResult(boolean complete, boolean canComplete, boolean event)
public Action.ActionResult()
Method Detail |
---|
public void combine(Action.ActionResult ar)
Sometimes multiple ActionResults need to be combined. For example Multiplexer calls several actions, but can only return a single result. Use the default constructor to start the combination process, use this method to process each ActionResult to combine, and use endCombine when they have all been combined.
The resulting ActionResult is set using these rules:
public Action.ActionResult endCombine()
This step is necessary because what is returned depends on whether any of the actions set canComplete.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |