|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--de.uni_paderborn.robots.logic.RobotTimer
This class is invented to control the individual time of each Robot. It will tell the GUI when more than 2 seconds have past (after the robot has began to calculate), thus the GUI can change the StatusWindow from the general view to the specific, robot-individual view.
| Field Summary | |
private boolean |
finished
true, after the robot has finished calculating, false otherwise. |
private Robot |
robot
The robot for this RobotTimer |
private long |
totalTimeOfRobot
The time the robot has needed so fra for ALL his rounds. |
private boolean |
visible
true, if the showStatusRobot() method of the GUI has been called, false otherwise. |
| Constructor Summary | |
(package private) |
RobotTimer(Robot robot)
Creates a new RobotTimer object. |
| Method Summary | |
(package private) boolean |
hasStarted()
returns if the thread has already started. |
void |
run()
to run the robotTimer |
(package private) void |
stopIt()
to stop the robotTimer |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
private Robot robot
private boolean finished
private boolean visible
private long totalTimeOfRobot
| Constructor Detail |
RobotTimer(Robot robot)
robot - The robot belonging to this RobotTimer.| Method Detail |
public void run()
run in interface java.lang.Runnablevoid stopIt()
boolean hasStarted()
true, if the run() method has already been called,
false otherwise.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||