public class MutableLongStats extends Object implements java.util.function.LongConsumer
Constructor and Description |
---|
MutableLongStats(long... distribution) |
Modifier and Type | Method and Description |
---|---|
void |
accept(long value) |
LongStats |
get() |
void |
merge(LongStats longStats) |
void |
reset() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
andThen
public MutableLongStats(long... distribution)
distribution
- is a list of long values, which are used to create distribution ranges for the long values
consumed by this MutableLongStats
via accept(long)
. For example::
if you pass in the following params: (1, 10, 100), the distributionStats
map will contain
the following entries:
accept(long)
long values in range: (-infinity, 1L]accept(long)
long values in range: (1L, 10L]accept(long)
long values in range: (10L, 100L]LongStats.MAX_DISTRIBUTION
, value: counter of all accepted accept(long)
long values in range: (100L, +infinity)public void accept(long value)
accept
in interface java.util.function.LongConsumer
public LongStats get()
public void reset()
public void merge(LongStats longStats)
Copyright © 2002-2021 Atlassian. All Rights Reserved.