
public class NanoDuration extends AbstractStatistic implements Duration
System.nanoTime()| Modifier and Type | Field and Description | 
|---|---|
(package private) long | 
begin
Tracking variables. 
 | 
(package private) long | 
end
Tracking variables. 
 | 
key| Constructor and Description | 
|---|
NanoDuration(String key)
Constructor. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
begin()
Start the timer. 
 | 
void | 
end()
Finish the timer. 
 | 
String | 
formatValue()
Get a formatted version of the value, for output. 
 | 
long | 
getBegin()
Get the begin of the interval. 
 | 
long | 
getDuration()
Get the duration of the interval. 
 | 
long | 
getEnd()
Get the end of the interval. 
 | 
getKey, toStringpublic NanoDuration(String key)
key - Keypublic void begin()
Durationpublic void end()
Durationpublic long getBegin()
Durationpublic long getEnd()
Durationpublic long getDuration()
DurationgetDuration in interface Durationpublic String formatValue()
StatisticformatValue in interface Statistic