|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectno.priv.garshol.duke.server.CommonJTimer
public class CommonJTimer
Timer implementation which uses the JSR-236 API, in order to provide managed threads within servlet containers that support them.
| Constructor Summary | |
|---|---|
CommonJTimer()
|
|
| Method Summary | |
|---|---|
void |
init(Properties props)
Initializes the timer, giving it access to configuration settings. |
boolean |
isRunning()
Returns true iff the background thread is running. |
void |
spawnThread(DukeController controller,
int check_interval)
Starts a background thread which calls the controller every check_interval milliseconds. |
void |
stop()
Stops the background thread. |
void |
timerExpired(commonj.timers.Timer timer)
This is the callback from the timer service, letting us know it's time do something. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CommonJTimer()
| Method Detail |
|---|
public void init(Properties props)
DukeTimer
init in interface DukeTimer
public void spawnThread(DukeController controller,
int check_interval)
spawnThread in interface DukeTimerpublic boolean isRunning()
isRunning in interface DukeTimerpublic void stop()
stop in interface DukeTimerpublic void timerExpired(commonj.timers.Timer timer)
timerExpired in interface commonj.timers.TimerListener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||