Class CarGenerator

java.lang.Object
  |
  +--CarGenerator
All Implemented Interfaces:
Timed

public class CarGenerator
extends java.lang.Object
implements Timed


Field Summary
protected  RoadNetwork roadNetwork
           
protected  TimeManager ticker
           
 
Constructor Summary
CarGenerator(RoadNetwork roadNetwork, int speed)
           
 
Method Summary
 void addToTimer(TimeManager theTick)
           
 void kill()
           
 void pretick()
           
 void setCarSpeeds(int index)
           
 void tick()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

roadNetwork

protected RoadNetwork roadNetwork

ticker

protected TimeManager ticker
Constructor Detail

CarGenerator

public CarGenerator(RoadNetwork roadNetwork,
                    int speed)
Method Detail

addToTimer

public void addToTimer(TimeManager theTick)

kill

public void kill()

pretick

public void pretick()
Specified by:
pretick in interface Timed

tick

public void tick()
Specified by:
tick in interface Timed

setCarSpeeds

public void setCarSpeeds(int index)