Class MetricValueSourceBase<T>
Provides the value of a metric and information about units. This is the class that metric consumers should use.
Inheritance
Inherited Members
Namespace:App.Metrics.Core.Abstractions
Assembly:cs.temp.dll.dll
Syntax
public abstract class MetricValueSourceBase<T>
Type Parameters
Name | Description |
---|---|
T | Type of the metric value |
Constructors
MetricValueSourceBase(String, IMetricValueProvider<T>, Unit, MetricTags)
Declaration
protected MetricValueSourceBase(string name, IMetricValueProvider<T> valueProvider, Unit unit, MetricTags tags)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | |
IMetricValueProvider<T> | valueProvider | |
Unit | unit | |
MetricTags | tags |
Properties
IsMultidimensional
Gets a value indicating whether this instance is a multidimensional metric.
Declaration
public bool IsMultidimensional { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
MultidimensionalName
Gets the name of the multidimensional metric. If tags were set at runtime, this will be the name of the metric without the concatenated metric tags so that these metrics can be reported as one.
Declaration
public string MultidimensionalName { get; }
Property Value
Type | Description |
---|---|
System.String | The name of the multidimensional metric. |
Name
Gets the Name of the metric.
Declaration
public string Name { get; }
Property Value
Type | Description |
---|---|
System.String | The name. |
Tags
Gets the Tags associated with the metric.
Declaration
public MetricTags Tags { get; }
Property Value
Type | Description |
---|---|
MetricTags | The tags. |
Unit
Gets the Unit representing what the metric is measuring.
Declaration
public Unit Unit { get; }
Property Value
Type | Description |
---|---|
Unit | The unit. |
Value
Gets the current value of the metric.
Declaration
public T Value { get; }
Property Value
Type | Description |
---|---|
T | The value. |
ValueProvider
Gets the instance capable of returning the current value for the metric.
Declaration
public IMetricValueProvider<T> ValueProvider { get; }
Property Value
Type | Description |
---|---|
IMetricValueProvider<T> | The value provider. |