@Immutable public abstract class MetricData extends Object
MetricData represents the data exported as part of aggregating one Instrument.| Modifier and Type | Class and Description |
|---|---|
static class |
MetricData.DoublePoint
DoublePoint is a single data point in a timeseries that describes the time-varying value of a
double metric.
|
static class |
MetricData.LongPoint
LongPoint is a single data point in a timeseries that describes the time-varying values of a
int64 metric.
|
static class |
MetricData.Point |
static class |
MetricData.SummaryPoint
SummaryPoint is a single data point that summarizes the values in a time series of numeric
values.
|
static class |
MetricData.Type
The kind of metric.
|
static class |
MetricData.ValueAtPercentile |
| Modifier and Type | Method and Description |
|---|---|
static MetricData |
create(io.opentelemetry.sdk.resources.Resource resource,
io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo,
String name,
String description,
String unit,
MetricData.Type type,
Collection<MetricData.Point> points) |
abstract String |
getDescription()
Returns the description of this metric.
|
abstract io.opentelemetry.sdk.common.InstrumentationLibraryInfo |
getInstrumentationLibraryInfo()
Returns the instrumentation library specified when creating the
Meter which created the
Instrument that produces MetricData. |
abstract String |
getName()
Returns the metric name.
|
abstract Collection<MetricData.Point> |
getPoints()
Returns the data
MetricData.Points for this metric. |
abstract io.opentelemetry.sdk.resources.Resource |
getResource()
Returns the resource of this
MetricData. |
abstract MetricData.Type |
getType()
Returns the type of this metric.
|
abstract String |
getUnit()
Returns the unit of this metric.
|
public abstract io.opentelemetry.sdk.resources.Resource getResource()
MetricData.MetricData.public abstract io.opentelemetry.sdk.common.InstrumentationLibraryInfo getInstrumentationLibraryInfo()
Meter which created the
Instrument that produces MetricData.InstrumentationLibraryInfopublic abstract String getName()
public abstract String getDescription()
public abstract String getUnit()
public abstract MetricData.Type getType()
public abstract Collection<MetricData.Point> getPoints()
MetricData.Points for this metric.
Only one type of points are available at any moment for a MetricData, and the type
is determined by the MetricData.Type.
MetricData.Points for this metric, or empty Collection if no points.public static MetricData create(io.opentelemetry.sdk.resources.Resource resource, io.opentelemetry.sdk.common.InstrumentationLibraryInfo instrumentationLibraryInfo, String name, String description, String unit, MetricData.Type type, Collection<MetricData.Point> points)