Located in compilation unit of java.
Modifier and Type | Field and Description |
---|---|
pack-priv boolean | newTasksMayBeScheduled
This flag is set to false by the reaper to inform us that there are no more live references to our Timer object. |
private TaskQueue | queue
Our Timer's queue. |
Access | Constructor and Description |
---|---|
pack-priv |
Modifier and Type | Method and Description |
---|---|
private void | |
public void | run()
Overrides java. Implements java. This method is run by the thread when it executes. |
newTasksMayBeScheduled | back to summary |
---|---|
pack-priv boolean newTasksMayBeScheduled This flag is set to false by the reaper to inform us that there are no more live references to our Timer object. Once this flag is true and there are no more tasks in our queue, there is no work left for us to do, so we terminate gracefully. Note that this field is protected by queue's monitor! |
queue | back to summary |
---|---|
private TaskQueue queue Our Timer's queue. We store this reference in preference to a reference to the Timer so the reference graph remains acyclic. Otherwise, the Timer would never be garbage-collected and this thread would never go away. |
TimerThread | back to summary |
---|---|
pack-priv TimerThread(TaskQueue queue) |
mainLoop | back to summary |
---|---|
private void mainLoop() The main timer loop. (See class comment.) |
run | back to summary |
---|---|
public void run() Overrides java. Implements java. Doc from java. This method is run by the thread when it executes. Subclasses of This method is not intended to be invoked directly. If this thread is a
platform thread created with a |