Package software.amazon.awssdk.metrics
Interface MetricCollection
-
- All Superinterfaces:
Iterable<MetricRecord<?>>
- All Known Implementing Classes:
DefaultMetricCollection,EmptyMetricCollection
public interface MetricCollection extends Iterable<MetricRecord<?>>
An immutable collection of metrics.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description List<MetricCollection>children()default Stream<MetricCollection>childrenWithName(String name)Return all of thechildren()with a specific name.InstantcreationTime()<T> List<T>metricValues(SdkMetric<T> metric)Return all the values of the given metric.Stringname()default Stream<MetricRecord<?>>stream()Return a stream of records in this collection.-
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
-
-
-
Method Detail
-
name
String name()
- Returns:
- The name of this metric collection.
-
stream
default Stream<MetricRecord<?>> stream()
Return a stream of records in this collection.
-
metricValues
<T> List<T> metricValues(SdkMetric<T> metric)
Return all the values of the given metric.- Type Parameters:
T- The type of the value.- Parameters:
metric- The metric.- Returns:
- All of the values of this metric.
-
children
List<MetricCollection> children()
- Returns:
- The child metric collections.
-
childrenWithName
default Stream<MetricCollection> childrenWithName(String name)
Return all of thechildren()with a specific name.- Parameters:
name- The name by which we will filterchildren().- Returns:
- The child metric collections that have the provided name.
-
creationTime
Instant creationTime()
- Returns:
- The time at which this collection was created.
-
-