Object
Exemplars
Immutable container for Exemplars.
This is currently backed by a List<Exemplar>. May be refactored later to use a more efficient data structure.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic Exemplars.Builderbuilder()get(double lowerBound, double upperBound) This is used by classic histograms to find an exemplar with a value between lowerBound and upperBound.get(int index) Find the Exemplar with the newest timestamp.iterator()static ExemplarsCreate a new Exemplars instance.static Exemplarsof(Collection<Exemplar> exemplars) Create a new Exemplars instance.intsize()Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Field Details
-
EMPTY
EMPTY means no Exemplars.
-
-
Method Details
-
of
Create a new Exemplars instance. You can either create Exemplars with one of the staticExemplars.of(...)methods, or you can use thebuilder().- Parameters:
exemplars- a copy of the exemplars collection will be created.
-
of
Create a new Exemplars instance. You can either create Exemplars with one of the staticExemplars.of(...)methods, or you can use thebuilder().- Parameters:
exemplars- a copy of the exemplars array will be created.
-
iterator
-
size
-
get
-
get
This is used by classic histograms to find an exemplar with a value between lowerBound and upperBound. If there is more than one exemplar within the bounds the one with the newest time stamp is returned. -
getLatest
Find the Exemplar with the newest timestamp. May returnnull. -
builder
-