public interface FunctionTimer extends Meter
Modifier and Type | Interface and Description |
---|---|
static class |
FunctionTimer.Builder<T> |
Meter.Id, Meter.Type
Modifier and Type | Method and Description |
---|---|
java.util.concurrent.TimeUnit |
baseTimeUnit() |
static <T> FunctionTimer.Builder<T> |
builder(java.lang.String name,
T obj,
java.util.function.ToLongFunction<T> countFunction,
java.util.function.ToDoubleFunction<T> totalTimeFunction,
java.util.concurrent.TimeUnit totalTimeFunctionUnits) |
long |
count()
The total number of occurrences of the timed event.
|
default double |
mean(java.util.concurrent.TimeUnit unit) |
default java.lang.Iterable<Measurement> |
measure()
Get a set of measurements.
|
double |
totalTime(java.util.concurrent.TimeUnit unit)
The total time of all occurrences of the timed event.
|
long count()
double totalTime(java.util.concurrent.TimeUnit unit)
default double mean(java.util.concurrent.TimeUnit unit)
java.util.concurrent.TimeUnit baseTimeUnit()
default java.lang.Iterable<Measurement> measure()
Meter
static <T> FunctionTimer.Builder<T> builder(java.lang.String name, T obj, java.util.function.ToLongFunction<T> countFunction, java.util.function.ToDoubleFunction<T> totalTimeFunction, java.util.concurrent.TimeUnit totalTimeFunctionUnits)