org.intranet.elevator.model.operate.controller
Interface Controller
- All Known Implementing Classes:
- MetaController, SimpleController
- public interface Controller
initialize
public void initialize(EventQueue eQ)
requestCar
public void requestCar(Floor newFloor,
Direction d)
addCar
public void addCar(Car car,
float stoppingDistance)
arrive
public boolean arrive(Car car)
- To be called only once when a car arrives at a location. This allows the
controller to update any internal data structures that were keeping track
of where the car was going to.
- Parameters:
car
- The car that is arriving.
- Returns:
- Whether the car is going up after this arrival. Can be used to
set the direction light on the entrance.
setNextDestination
public void setNextDestination(Car car)