mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-25 14:24:35 +00:00
23 lines
472 B
Java
23 lines
472 B
Java
package mekanism.common.util;
|
|
|
|
public class DebugUtils {
|
|
|
|
private static long prevNanoTime;
|
|
|
|
public static void startTracking() {
|
|
prevNanoTime = System.nanoTime();
|
|
}
|
|
|
|
public static long getTrackedNanos() {
|
|
return System.nanoTime() - prevNanoTime;
|
|
}
|
|
|
|
public static long getTrackedMicros() {
|
|
return getTrackedNanos() / 1000;
|
|
}
|
|
|
|
public static long getTrackedMillis() {
|
|
return getTrackedMicros() / 1000;
|
|
}
|
|
}
|