chord.util
Class StopWatch

java.lang.Object
  extended by chord.util.StopWatch

public class StopWatch
extends java.lang.Object

Simple class for measuring elapsed time.

Author:
Percy Liang (pliang@cs.berkeley.edu)

Field Summary
 long endTime
           
 long ms
           
 int n
           
 long startTime
           
 
Constructor Summary
StopWatch()
           
StopWatch(long ms)
           
 
Method Summary
 StopWatch accumStop()
           
 void add(StopWatch w)
           
 long getCurrTimeLong()
           
 boolean isRunning()
           
 void reset()
           
 StopWatch start()
           
 StopWatch stop()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

startTime

public long startTime

endTime

public long endTime

ms

public long ms

n

public int n
Constructor Detail

StopWatch

public StopWatch()

StopWatch

public StopWatch(long ms)
Method Detail

reset

public void reset()

start

public StopWatch start()

stop

public StopWatch stop()

accumStop

public StopWatch accumStop()

add

public void add(StopWatch w)

getCurrTimeLong

public long getCurrTimeLong()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

isRunning

public boolean isRunning()