All Packages Class Hierarchy This Package Previous Next Index
Class gpsys.lawnmower.Left
java.lang.Object
|
+----gpsys.Primitive
|
+----gpsys.Terminal
|
+----gpsys.lawnmower.Left
- public class Left
- extends Terminal
Vector2Mod8 Left
A Terminal that instructs the lawnmower to turn left by 90 degrees.
- Author:
- Adil Qureshi
Department of Computer Science,
University College London,
Gower St,
London WC1E 6BT,
UK.
- See Also:
- Primitive, Terminal
-
Left(Mower)
- Create a new Left terminal which controls the specified lawn mower.
-
evaluateObject(Individual)
- Evaluates this Terminal, causing the mower to turn left by 90 degrees.
-
instance()
- Creates a new instance of this Object.
-
toString()
- Returns a String representation of this Terminal.
Left
public Left(Mower mower)
- Create a new Left terminal which controls the specified lawn mower.
- Parameters:
- mower - The mower to be controlled.
evaluateObject
public final Object evaluateObject(Individual i)
- Evaluates this Terminal, causing the mower to turn left by 90 degrees.
- Parameters:
- i - The individual being evaluated.
- Returns:
- An Object (actually a Vector2Mod8) representing the
Zero Vector2Mod8.
- Overrides:
- evaluateObject in class Terminal
instance
public final Primitive instance()
- Creates a new instance of this Object.
- Returns:
- A reference to this same Object since none of the instance
variables are to be changed.
- Overrides:
- instance in class Primitive
toString
public String toString()
- Returns a String representation of this Terminal.
- Returns:
- A String containing the name of the Terminal.
- Overrides:
- toString in class Primitive
All Packages Class Hierarchy This Package Previous Next Index