|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--gpsys.Gene
|
+--gpsys.GeneFunction
A GeneFunction is a Gene tree representing a function call. A GeneFunction therefore has Gene arguments (branches or subtrees).
Gene,
GeneFunctionGrow,
GeneFunctionFull, Serialized Form| Field Summary | |
Gene[] |
arguments
The arguments for this function call. |
| Fields inherited from class gpsys.Gene |
p |
| Constructor Summary | |
GeneFunction()
|
|
| Method Summary | |
int |
complexity()
Get the number of Genes in this Gene tree. |
Gene |
deepClone()
Make a clone of this Gene tree, cloning all subtrees. |
int |
depth()
Get the maximum depth of this Gene tree |
boolean |
evaluateBoolean(Individual i)
Evaluate this Gene as Function returning a boolean. |
byte |
evaluateByte(Individual i)
Evaluate this Gene as Function returning a byte. |
char |
evaluateChar(Individual i)
Evaluate this Gene as Function returning a char. |
double |
evaluateDouble(Individual i)
Evaluate this Gene as Function returning a double. |
float |
evaluateFloat(Individual i)
Evaluate this Gene as Function returning a float. |
int |
evaluateInt(Individual i)
Evaluate this Gene as Function returning an int. |
long |
evaluateLong(Individual i)
Evaluate this Gene as Function returning a long. |
java.lang.Object |
evaluateObject(Individual i)
Evaluate this Gene as Function returning an Object reference. |
short |
evaluateShort(Individual i)
Evaluate this Gene as Function returning a short. |
java.lang.String |
toString()
Create a String representing this Gene tree. |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
public Gene[] arguments
| Constructor Detail |
public GeneFunction()
| Method Detail |
public java.lang.Object evaluateObject(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public byte evaluateByte(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public short evaluateShort(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public int evaluateInt(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public long evaluateLong(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public float evaluateFloat(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public double evaluateDouble(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public char evaluateChar(Individual i)
throws EvaluationException
i - the individual to which this Gene belongs
public boolean evaluateBoolean(Individual i)
throws EvaluationException
i - the individual to which this Gene belongspublic int depth()
public int complexity()
public Gene deepClone()
public java.lang.String toString()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||