|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.epochx.representation.Node<TYPE>
com.epochx.representation.FunctionNode<Action>
com.epochx.representation.action.Seq3Function
public class Seq3Function
A FunctionNode which provides the facility to sequence three
instructions - which may be other functions or terminal nodes with actions.
| Constructor Summary | |
|---|---|
Seq3Function()
Construct a Seq3Function with no children. |
|
Seq3Function(Node<Action> child1,
Node<Action> child2,
Node<Action> child3)
Construct a Seq3Function with two children. |
|
| Method Summary | |
|---|---|
Action |
evaluate()
Evaluating a Seq3Function involves evaluating each of the
children in sequence - the first child node, followed by the second
child node, followed by the third child node. |
java.lang.String |
getFunctionName()
Get the unique name that identifies this function. |
| Methods inherited from class com.epochx.representation.FunctionNode |
|---|
equals, toString |
| Methods inherited from class com.epochx.representation.Node |
|---|
clone, getArity, getChild, getChildren, getDepth, getFunctionNodes, getLength, getNodesAtDepth, getNoDistinctFunctions, getNoDistinctTerminals, getNoFunctions, getNoTerminals, getNthNode, getTerminalNodes, hashCode, setChild, setChildren, setNthNode |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Seq3Function()
public Seq3Function(Node<Action> child1,
Node<Action> child2,
Node<Action> child3)
child1 - The first child node to be executed first in sequence.child2 - The second child node to be executed second in sequence.child3 - The third child node to be executed third in sequence.| Method Detail |
|---|
public Action evaluate()
Seq3Function involves evaluating each of the
children in sequence - the first child node, followed by the second
child node, followed by the third child node.
Each of the children will thus have been evaluated (triggering
execution of actions at the TerminalNodes) and then this
method which must return an Action, returns Action.DO_NOTHING which any
functions higher up in the program tree will execute, but with no
effect.
evaluate in class Node<Action>public java.lang.String getFunctionName()
getFunctionName in class FunctionNode<Action>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||