Package org.jboss.util
Class StopWatch.Wrapper
- java.lang.Object
-
- org.jboss.util.StopWatch
-
- org.jboss.util.StopWatch.Wrapper
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longgetAverageLapTime()Get the average lap time since the watch was started.intgetLapCount()Get the lap count.longgetLapTime()Get the elapsed lap time since the watch was started.longgetTime()Get the elapsed time since the watch was created or last reset.booleanisRunning()Check if the watch is running.voidreset()Reset the watch.voidstart()Start the watch.voidstart(boolean reset)Start the watch.longstop()Stop the watch.java.lang.StringtoString()Return a string representation.-
Methods inherited from class org.jboss.util.StopWatch
clone, makeSynchronized
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
The serialVersionUID- See Also:
- Constant Field Values
-
watch
protected StopWatch watch
-
-
Constructor Detail
-
Wrapper
public Wrapper(StopWatch watch)
-
-
Method Detail
-
start
public void start(boolean reset)
Description copied from class:StopWatchStart the watch.
-
start
public void start()
Description copied from class:StopWatchStart the watch.
-
stop
public long stop()
Description copied from class:StopWatchStop the watch.
-
reset
public void reset()
Description copied from class:StopWatchReset the watch.
-
getLapTime
public long getLapTime()
Description copied from class:StopWatchGet the elapsed lap time since the watch was started.- Overrides:
getLapTimein classStopWatch- Returns:
- Elapsed lap time or 0 if the watch was never started
-
getAverageLapTime
public long getAverageLapTime()
Description copied from class:StopWatchGet the average lap time since the watch was started.- Overrides:
getAverageLapTimein classStopWatch- Returns:
- Average lap time since the watch was started.
-
getLapCount
public int getLapCount()
Description copied from class:StopWatchGet the lap count.- Overrides:
getLapCountin classStopWatch- Returns:
- The lap count.
-
getTime
public long getTime()
Description copied from class:StopWatchGet the elapsed time since the watch was created or last reset.
-
isRunning
public boolean isRunning()
Description copied from class:StopWatchCheck if the watch is running.
-
-