org.limitless.util
Class InterruptableTimeout

java.lang.Object
  extended by org.limitless.util.InterruptableTimeout
All Implemented Interfaces:
java.lang.Runnable

public class InterruptableTimeout
extends java.lang.Object
implements java.lang.Runnable

This class takes an object and a timeout, and when the timeout occurs, if it hasn't been aborted, it invokes "go" on the object.


Nested Class Summary
static interface InterruptableTimeout.OnTimeout
           
 
Field Summary
(package private)  boolean killAborted
           
(package private) static org.apache.log4j.Logger logger
          Log4J Logger
private  InterruptableTimeout.OnTimeout timeoutHandler
           
(package private)  java.lang.Thread timeThread
           
private  long timeToExpire
           
 
Constructor Summary
InterruptableTimeout(int secondsToWait, InterruptableTimeout.OnTimeout what)
           
 
Method Summary
 void done()
           
 void run()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

static org.apache.log4j.Logger logger
Log4J Logger


timeoutHandler

private InterruptableTimeout.OnTimeout timeoutHandler

timeToExpire

private long timeToExpire

timeThread

java.lang.Thread timeThread

killAborted

boolean killAborted
Constructor Detail

InterruptableTimeout

public InterruptableTimeout(int secondsToWait,
                            InterruptableTimeout.OnTimeout what)
Method Detail

run

public void run()
Specified by:
run in interface java.lang.Runnable

done

public void done()


Copyright © 1995, 2004 Limitless Knowledge Association, All Rights Reserved.