Class ContinuousStopwatch

java.lang.Object
com.google.inject.internal.util.ContinuousStopwatch

@NotThreadSafe public final class ContinuousStopwatch extends Object
A continuously timing stopwatch that is used for simple performance monitoring.
Author:
crazybob@google.com (Bob Lee)
  • Constructor Details

    • ContinuousStopwatch

      public ContinuousStopwatch(com.google.common.base.Stopwatch stopwatch)
      Constructs a ContinuousStopwatch, which will start timing immediately after construction.
      Parameters:
      stopwatch - the internal stopwatch used by ContinuousStopwatch
  • Method Details

    • reset

      public long reset()
      Resets and returns elapsed time in milliseconds.
    • resetAndLog

      public void resetAndLog(String label)
      Resets and logs elapsed time in milliseconds.