de.jaetzold.art.examples
Class TrustySimpleAlgorithm

java.lang.Object
  |
  +--de.jaetzold.art.examples.TrustySimpleAlgorithm
All Implemented Interfaces:
Trusty

public class TrustySimpleAlgorithm
extends Object
implements Trusty


Inner Class Summary
static interface TrustySimpleAlgorithm.Robot
           
 
Field Summary
protected  double backupMeters
           
protected  PropertyChangeSupport changes
           
protected  NormalizedDriveTrain driveTrain
           
protected  double turnAngle
           
 
Fields inherited from interface de.jaetzold.art.examples.Trusty
AVOID_LEFT, AVOID_RIGHT, MOVE, STOP
 
Constructor Summary
TrustySimpleAlgorithm()
           
TrustySimpleAlgorithm(TrustySimpleAlgorithm.Robot robot)
           
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener l)
           
 void avoidLeft()
           
 void avoidRight()
           
 int getState()
           
static void main(String[] argv)
           
 void move()
           
 void removePropertyChangeListener(PropertyChangeListener l)
           
protected  void setState(int state)
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

driveTrain

protected NormalizedDriveTrain driveTrain

backupMeters

protected double backupMeters

turnAngle

protected double turnAngle

changes

protected PropertyChangeSupport changes
Constructor Detail

TrustySimpleAlgorithm

public TrustySimpleAlgorithm(TrustySimpleAlgorithm.Robot robot)

TrustySimpleAlgorithm

public TrustySimpleAlgorithm()
                      throws Exception
Method Detail

avoidLeft

public void avoidLeft()
Specified by:
avoidLeft in interface Trusty

avoidRight

public void avoidRight()
Specified by:
avoidRight in interface Trusty

stop

public void stop()
Specified by:
stop in interface Trusty

move

public void move()
Specified by:
move in interface Trusty

setState

protected void setState(int state)

addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener l)

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener l)

getState

public int getState()
Specified by:
getState in interface Trusty

main

public static void main(String[] argv)
                 throws Exception