Class MetricDescriptor
java.lang.Object
io.opencensus.metrics.export.MetricDescriptor
- Direct Known Subclasses:
AutoValue_MetricDescriptor
MetricDescriptor defines a Metric type and its schema.- Since:
- 0.17
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic MetricDescriptorcreate(String name, String description, String unit, MetricDescriptor.Type type, List<LabelKey> labelKeys) Creates aMetricDescriptor.abstract StringReturns the description of this metric descriptor.Returns the label keys associated with this metric descriptor.abstract StringgetName()Returns the metric descriptor name.abstract MetricDescriptor.TypegetType()Returns the type of this metric descriptor.abstract StringgetUnit()Returns the unit of this metric descriptor.
-
Constructor Details
-
MetricDescriptor
MetricDescriptor()
-
-
Method Details
-
create
public static MetricDescriptor create(String name, String description, String unit, MetricDescriptor.Type type, List<LabelKey> labelKeys) Creates aMetricDescriptor.- Parameters:
name- name ofMetricDescriptor.description- description ofMetricDescriptor.unit- the metric unit.type- type ofMetricDescriptor.labelKeys- the label keys associated with theMetricDescriptor.- Returns:
- a
MetricDescriptor. - Since:
- 0.17
-
getName
Returns the metric descriptor name.- Returns:
- the metric descriptor name.
- Since:
- 0.17
-
getDescription
Returns the description of this metric descriptor.- Returns:
- the description of this metric descriptor.
- Since:
- 0.17
-
getUnit
Returns the unit of this metric descriptor.- Returns:
- the unit of this metric descriptor.
- Since:
- 0.17
-
getType
Returns the type of this metric descriptor.- Returns:
- the type of this metric descriptor.
- Since:
- 0.17
-
getLabelKeys
-