proper.util
Class Stopwatch

java.lang.Object
  extended by proper.util.Stopwatch

public class Stopwatch
extends java.lang.Object

This class provides a simple method to measure runtime behaviour.

Version:
$Revision: 1.2 $
Author:
FracPete

Constructor Summary
Stopwatch()
          initializes the object
 
Method Summary
 long getMilliSeconds()
          returns the milliseconds
 long getSeconds()
          returns the seconds
 void start()
          starts the "clock"
 void stop()
          stops the "clock"
 java.lang.String toString()
          returns the time in Seconds
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Stopwatch

public Stopwatch()
initializes the object

Method Detail

start

public void start()
starts the "clock"


stop

public void stop()
stops the "clock"


getSeconds

public long getSeconds()
returns the seconds

Returns:
the stopped time in seconds

getMilliSeconds

public long getMilliSeconds()
returns the milliseconds

Returns:
the stopped time in milliseconds

toString

public java.lang.String toString()
returns the time in Seconds

Overrides:
toString in class java.lang.Object