avrora.sim.util
Class GlobalClock
java.lang.Object
avrora.sim.util.GlobalClock
- public class GlobalClock
- extends java.lang.Object
The GlobalClock class implements a global timer among multiple
simulators by inserting periodic timers into each simulator.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
period
protected double period
goal
protected int goal
count
protected int count
condition
protected final java.lang.Object condition
threadMap
protected final java.util.HashMap threadMap
eventQueue
protected final DeltaQueue eventQueue
GlobalClock
public GlobalClock(double p)
add
public void add(SimulatorThread t)
remove
public void remove(SimulatorThread t)
addTimerEvent
public void addTimerEvent(Simulator.Trigger trigger,
long ticks)
removeTimerEvent
public void removeTimerEvent(Simulator.Trigger trigger)
tick
protected void tick()