Interface Reservoir
-
- All Known Implementing Classes:
ExponentiallyDecayingReservoir
public interface ReservoirA statistically representative reservoir of a data stream.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.eclipse.microprofile.metrics.SnapshotgetSnapshot()Returns a snapshot of the reservoir's values.intsize()Returns the number of values recorded.voidupdate(long value)Adds a new recorded value to the reservoir.
-
-
-
Method Detail
-
size
int size()
Returns the number of values recorded.- Returns:
- the number of values recorded
-
update
void update(long value)
Adds a new recorded value to the reservoir.- Parameters:
value- a new recorded value
-
getSnapshot
org.eclipse.microprofile.metrics.Snapshot getSnapshot()
Returns a snapshot of the reservoir's values.- Returns:
- a snapshot of the reservoir's values
-
-