Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.antcontrib.perf
Class AntPerformanceListener.StopWatch

    java.lang.Object
      |
      +--net.sf.antcontrib.perf.AntPerformanceListener.StopWatch

Enclosing class:
  AntPerformanceListener

public class AntPerformanceListener.StopWatch
extends java.lang.Object

A stopwatch, useful for 'quick and dirty' performance testing.

Version:
  $Revision: 1.2 $
Author:
  Dale Anson

Constructor Summary
`AntPerformanceListener.StopWatch()` Starts the stopwatch.

Method Summary
`long` | `elapsed()` Elapsed time, difference between the last start time and now.
`long` | `start()` Starts/restarts the stopwatch.
`long` | `stop()` Stops the stopwatch.
`long` | `total()` Total cumulative elapsed time.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AntPerformanceListener.StopWatch

    public AntPerformanceListener.StopWatch()

  Starts the stopwatch.

Method Detail

### start

    public long start()

  Starts/restarts the stopwatch.

  Returns:
    the start time, the long returned System.currentTimeMillis().

### stop

    public long stop()

  Stops the stopwatch.

  Returns:
    the stop time, the long returned System.currentTimeMillis().

### total

    public long total()

  Total cumulative elapsed time.

  Returns:
    the total time

### elapsed

    public long elapsed()

  Elapsed time, difference between the last start time and now.

  Returns:
    the elapsed time

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD