java.lang.Objectrcs.nml.time_tracker
public class time_tracker
Simple class to track wall-clock performace time. All times are given in seconds but precise to .001 s. (Exact accuracy depends on Operating System, JRE etc ) Absolute times are in seconds since Jan,1 1970 UTC aka "unix time" although see the pages for System.currentTimeMillis()
| Field Summary | |
|---|---|
double |
avg
Average differenc in time between consecutive calls to cycle(). |
int |
count
Number of times cycle was called since last reset. |
double |
elapsed
Current time minus start. |
double |
last
Last time cycle was called |
double |
max
Maximum difference in time between consecutive calls to cycle() |
double |
min
Minimum difference in time between consecutive calls to cycle() |
double |
now
Deprecated. Redundant with last. |
double |
start
Time when constructed or reset. |
| Constructor Summary | |
|---|---|
time_tracker()
|
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
|
void |
cycle()
Called periodically to measure the wall clock statistics of a periodic function. |
void |
reset()
Reset all statistics and start the clock from now. |
void |
update(NMLFormatConverter nml_fc)
|
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public int count
public double last
public double now
public double start
public double elapsed
public double min
public double max
public double avg
| Constructor Detail |
|---|
public time_tracker()
| Method Detail |
|---|
public void reset()
public void cycle()
public void update(NMLFormatConverter nml_fc)
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone in class java.lang.Objectjava.lang.CloneNotSupportedException