Class Timer.Context

java.lang.Object
com.codahale.metrics.Timer.Context
All Implemented Interfaces:
Closeable, AutoCloseable
Enclosing class:
Timer

public static class Timer.Context extends Object implements Closeable
A timing context.
See Also:
  • Method Details

    • stop

      public long stop()
      Stops recording the elapsed time, updates the timer and returns the elapsed time in nanoseconds.
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable