Package io.ebean.metric
Interface TimedMetric
-
public interface TimedMetric
Metric for timed events like transaction execution times.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
add(long micros)
Add a time event (usually in microseconds).void
addBatchSince(long startNanos, int batch)
Add a time event for a batch of beans.void
addSinceNanos(long startNanos)
Add a time event given the start nanos.TimedMetricStats
collect(boolean reset)
Collect and return a snapshot of the metrics.boolean
isEmpty()
Return true if there are no metrics collected since the last collection.void
reset()
Reset the statistics.void
visit(MetricVisitor visitor)
Visit non empty metrics.
-
-
-
Method Detail
-
add
void add(long micros)
Add a time event (usually in microseconds).
-
addBatchSince
void addBatchSince(long startNanos, int batch)
Add a time event for a batch of beans.
-
addSinceNanos
void addSinceNanos(long startNanos)
Add a time event given the start nanos.
-
isEmpty
boolean isEmpty()
Return true if there are no metrics collected since the last collection.
-
reset
void reset()
Reset the statistics.
-
collect
TimedMetricStats collect(boolean reset)
Collect and return a snapshot of the metrics.
-
visit
void visit(MetricVisitor visitor)
Visit non empty metrics.
-
-