com.meiglobal.ebds.api.util
Class CustomTimer

java.lang.Object
  extended by com.meiglobal.ebds.api.util.CustomTimer
All Implemented Interfaces:
java.lang.Runnable

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

Custom timer class used to detect when a message has failed to be sent.


Constructor Summary
CustomTimer(long timeout)
          Constructor
 
Method Summary
 void addTimeoutObserver(Timeoutable to)
           
protected  void fireTimeoutOccured()
           
 void removeTimeoutObserver(Timeoutable to)
           
 void run()
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CustomTimer

public CustomTimer(long timeout)
            throws java.lang.IllegalArgumentException
Constructor

Parameters:
timeout - Value in milliseconds for the timeout.
Throws:
java.lang.IllegalArgumentException - If the timeout value is less than 1.
Method Detail

addTimeoutObserver

public void addTimeoutObserver(Timeoutable to)

removeTimeoutObserver

public void removeTimeoutObserver(Timeoutable to)

fireTimeoutOccured

protected final void fireTimeoutOccured()

start

public void start()

stop

public void stop()

run

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