Package io.opentelemetry.sdk.metrics
Class View
- java.lang.Object
-
- io.opentelemetry.sdk.metrics.View
-
- Direct Known Subclasses:
AutoValue_View
@Immutable public abstract class View extends java.lang.ObjectA view configures how measurements are aggregated and exported as metrics.Views are registered with the SDK
SdkMeterProviderBuilder.registerView(InstrumentSelector, View).- Since:
- 1.14.0
-
-
Constructor Summary
Constructors Constructor Description View()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static ViewBuilderbuilder()(package private) static Viewcreate(java.lang.String name, java.lang.String description, Aggregation aggregation, AttributesProcessor attributesProcessor, int cardinalityLimit)abstract AggregationgetAggregation()Returns the aggregation of the resulting metric.(package private) abstract AttributesProcessorgetAttributesProcessor()Returns the attribute processor used for this view.abstract intgetCardinalityLimit()Returns the cardinality limit for this view.abstract java.lang.StringgetDescription()Returns the description of the resulting metric, ornullif the matched instrument description should be used.abstract java.lang.StringgetName()Returns the name of the resulting metric, ornullif the matched instrument name should be used.java.lang.StringtoString()
-
-
-
Method Detail
-
builder
public static ViewBuilder builder()
-
create
static View create(@Nullable java.lang.String name, @Nullable java.lang.String description, Aggregation aggregation, AttributesProcessor attributesProcessor, int cardinalityLimit)
-
getName
@Nullable public abstract java.lang.String getName()
Returns the name of the resulting metric, ornullif the matched instrument name should be used.
-
getDescription
@Nullable public abstract java.lang.String getDescription()
Returns the description of the resulting metric, ornullif the matched instrument description should be used.
-
getAggregation
public abstract Aggregation getAggregation()
Returns the aggregation of the resulting metric.
-
getAttributesProcessor
abstract AttributesProcessor getAttributesProcessor()
Returns the attribute processor used for this view.
-
getCardinalityLimit
public abstract int getCardinalityLimit()
Returns the cardinality limit for this view.- Since:
- 1.44.0
-
toString
public final java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-