org.openware.loadsim.simulation
Class ConstantTimer

java.lang.Object
  |
  +--org.openware.loadsim.simulation.ConstantTimer
All Implemented Interfaces:
ITimer, java.io.Serializable

public class ConstantTimer
extends java.lang.Object
implements ITimer

Implements a Constant based timer.

Author:
Vincent Sheffer.
See Also:
Serialized Form

Constructor Summary
ConstantTimer(org.w3c.dom.Node node)
           
 
Method Summary
 java.lang.String getId()
          Get the ID of the timer.
 long nextDelay()
          Get the next delay for this timer.
 java.lang.String toString()
          Return a String representation of the ConstantTimer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ConstantTimer

public ConstantTimer(org.w3c.dom.Node node)
              throws ConfigException
Method Detail

nextDelay

public long nextDelay()
Get the next delay for this timer.
Specified by:
nextDelay in interface ITimer
Returns:
The next delay that can be used in a Thread.sleep() method.

getId

public java.lang.String getId()
Get the ID of the timer. The ID is used to reference the timer in the configuration file.
Specified by:
getId in interface ITimer
Returns:
The ID of the timer.

toString

public java.lang.String toString()
Return a String representation of the ConstantTimer.
Overrides:
toString in class java.lang.Object
Returns:
a String representation of the ConstantTimer.


Copyright © 2000, 2001 Openware, Spin Software. All Rights Reserved.