|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectec.gp.ge.GrammarNode
ec.gp.ge.GrammarFunctionNode
public class GrammarFunctionNode
A GrammarNode representing a GPNode in the GE Grammar. The head of the GrammarFunctionNode is the name of the GPNode in the grammar; and the children are various arguments to the node as defined by the grammar. These are returned by getArgument(...) and getNumArguments(). The GrammarFunctionNode holds a prototypical GPNode from which clones can be made.
Field Summary |
---|
Fields inherited from class ec.gp.ge.GrammarNode |
---|
children |
Constructor Summary | |
---|---|
GrammarFunctionNode(GPFunctionSet gpfs,
java.lang.String name)
Determines the GPNode from the function set by the name. |
Method Summary | |
---|---|
void |
addArgument(GrammarNode arg)
Adds a given argument to the node. |
GrammarNode |
getArgument(int index)
Returna given argument. |
GPNode |
getGPNodePrototype()
Returns the prototype without cloning it first. |
int |
getNumArguments()
Returns the number of arguments. |
java.lang.String |
toString()
|
Methods inherited from class ec.gp.ge.GrammarNode |
---|
getHead |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public GrammarFunctionNode(GPFunctionSet gpfs, java.lang.String name)
Method Detail |
---|
public void addArgument(GrammarNode arg)
public int getNumArguments()
public GrammarNode getArgument(int index)
public GPNode getGPNodePrototype()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |