All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.sksamuel.scam.Stopwatch.scala Maven / Gradle / Ivy

package com.sksamuel.scam

import scala.concurrent.duration._

/** @author Stephen Samuel */
class Stopwatch {
  var _start = 0l
  var _end = 0l
  def start() = {
    _start = System.nanoTime()
  }
  def stop() = {
    _end = System.nanoTime()
  }
  def elapsed: FiniteDuration = (_end - _start).nanos
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy