Class MetricSnapshots
Object
MetricSnapshots
- All Implemented Interfaces:
Iterable<MetricSnapshot>
Immutable list of metric snapshots.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionMetricSnapshots(MetricSnapshot... snapshots) MetricSnapshots(Collection<MetricSnapshot> snapshots) To create MetricSnapshots, you can either call the constructor directly or usebuilder(). -
Method Summary
Modifier and TypeMethodDescriptionstatic MetricSnapshots.Builderbuilder()get(int i) iterator()static MetricSnapshotsof(MetricSnapshot... snapshots) intsize()stream()Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Constructor Details
-
MetricSnapshots
-
MetricSnapshots
To create MetricSnapshots, you can either call the constructor directly or usebuilder().- Parameters:
snapshots- the constructor creates a sorted copy of snapshots.- Throws:
IllegalArgumentException- if snapshots contains duplicate metric names. To avoid duplicate metric names usebuilder()and checkMetricSnapshots.Builder.containsMetricName(String)before callingMetricSnapshots.Builder.metricSnapshot(MetricSnapshot).
-
-
Method Details
-
of
-
iterator
- Specified by:
iteratorin interfaceIterable<MetricSnapshot>
-
size
-
get
-
stream
-
builder
-