1 package org.simantics.db.procore.cluster;
3 //Simple class for measuring time.
6 public final void start() { // Starts measuring time.
7 start = System.nanoTime();
9 public final void stop() { // Ends measuring time, increases the amount of elapsed time.
10 time += (double)(System.nanoTime() - start) * (double)(1e-9);
12 public final void reset() { // Set elapsed time to zero.
15 public final void restart() { // Reset and starts measuring time.
19 public final double elapsed() { // Returns elapsed time in seconds.
22 public final double elapsedMilli() { // Returns elapsed time in milliseconds.