wodka.ga.geno.lang.turtle
Class Forward
java.lang.Object
wodka.ga.geno.lang.turtle.AbstractTurtleCommand
wodka.ga.geno.lang.turtle.Forward
- All Implemented Interfaces:
- Command, java.io.Serializable, StreamPersistable, TurtleCommand
- public class Forward
- extends AbstractTurtleCommand
Forward command. Moves the model building turtle a certain distance.
- See Also:
- Serialized Form
Constructor Summary |
Forward()
|
Forward(int val,
double amplitude,
double phase)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Forward
public Forward()
Forward
public Forward(int val,
double amplitude,
double phase)
getAmplitude
public double getAmplitude()
setAmplitude
public void setAmplitude(double amplitude)
getPhase
public double getPhase()
setPhase
public void setPhase(double phase)
getVal
public int getVal()
setVal
public void setVal(int val)
toShortDescription
public java.lang.String toShortDescription()
mutateCommand
public Command mutateCommand(java.util.Random ran)
parameterCount
public int parameterCount()
mutateParameter
public void mutateParameter(int paramInt,
java.util.Random ran)
createClone
public Command createClone()
eval
public void eval(Model model,
TurtleInterpreter turtInter)
toStream
public void toStream(java.io.DataOutputStream outStream)
throws java.io.IOException
- Throws:
java.io.IOException
fromStream
public void fromStream(java.io.DataInputStream inStream,
int version)
throws java.io.IOException
- Throws:
java.io.IOException
getVersion
public int getVersion()