public class CompositeFunctionTimer<T> extends AbstractMeter implements FunctionTimer, CompositeMeter
Meter.Id, Meter.Type| Constructor and Description |
|---|
CompositeFunctionTimer(Meter.Id id,
T obj,
java.util.function.ToLongFunction<T> countFunction,
java.util.function.ToDoubleFunction<T> totalTimeFunction,
java.util.concurrent.TimeUnit totalTimeFunctionUnits) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(MeterRegistry registry) |
java.util.concurrent.TimeUnit |
baseTimeUnit() |
long |
count()
The total number of occurrences of the timed event.
|
void |
remove(MeterRegistry registry) |
double |
totalTime(java.util.concurrent.TimeUnit unit)
The total time of all occurrences of the timed event.
|
getIdclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitmeasurepublic void add(MeterRegistry registry)
add in interface CompositeMeterpublic void remove(MeterRegistry registry)
remove in interface CompositeMeterpublic long count()
FunctionTimercount in interface FunctionTimerpublic double totalTime(java.util.concurrent.TimeUnit unit)
FunctionTimertotalTime in interface FunctionTimerpublic java.util.concurrent.TimeUnit baseTimeUnit()
baseTimeUnit in interface FunctionTimer