net.i2p.util
Class SocketTimeout
java.lang.Object
net.i2p.util.SocketTimeout
- All Implemented Interfaces:
- SimpleTimer.TimedEvent
public class SocketTimeout
- extends java.lang.Object
- implements SimpleTimer.TimedEvent
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SocketTimeout
public SocketTimeout(long delay)
SocketTimeout
public SocketTimeout(java.net.Socket socket,
long delay)
timeReached
public void timeReached()
- Description copied from interface:
SimpleTimer.TimedEvent
- the time requested has been reached (this call should NOT block,
otherwise the whole SimpleTimer gets backed up)
- Specified by:
timeReached
in interface SimpleTimer.TimedEvent
cancel
public void cancel()
setSocket
public void setSocket(java.net.Socket s)
resetTimer
public void resetTimer()
setInactivityTimeout
public void setInactivityTimeout(long timeout)
setTotalTimeoutPeriod
public void setTotalTimeoutPeriod(long timeoutPeriod)
setTimeoutCommand
public void setTimeoutCommand(java.lang.Runnable job)
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object