Editare

Partajați prin


Meter.CreateGauge Method

Definition

Overloads

CreateGauge<T>(String)

Creates a Gauge instrument, which can be used to record non-additive values.

CreateGauge<T>(String, String, String, IEnumerable<KeyValuePair<String,Object>>)

Create a metrics Gauge object.

CreateGauge<T>(String)

Creates a Gauge instrument, which can be used to record non-additive values.

public:
generic <typename T>
 where T : value class System::Diagnostics::Metrics::Gauge<T> ^ CreateGauge(System::String ^ name);
public System.Diagnostics.Metrics.Gauge<T> CreateGauge<T> (string name) where T : struct;
member this.CreateGauge : string -> System.Diagnostics.Metrics.Gauge<'T (requires 'T : struct)> (requires 'T : struct)
Public Function CreateGauge(Of T As Structure) (name As String) As Gauge(Of T)

Type Parameters

T

Parameters

name
String

The instrument name. cannot be null.

Returns

Remarks

Gauge is an Instrument which used to record non-additive values.

Example uses for Gauge: record the room background noise level value when changes occur.

Applies to

CreateGauge<T>(String, String, String, IEnumerable<KeyValuePair<String,Object>>)

Create a metrics Gauge object.

public System.Diagnostics.Metrics.Gauge<T> CreateGauge<T> (string name, string? unit = default, string? description = default, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string,object?>>? tags = default) where T : struct;
member this.CreateGauge : string * string * string * seq<System.Collections.Generic.KeyValuePair<string, obj>> -> System.Diagnostics.Metrics.Gauge<'T (requires 'T : struct)> (requires 'T : struct)
Public Function CreateGauge(Of T As Structure) (name As String, Optional unit As String = Nothing, Optional description As String = Nothing, Optional tags As IEnumerable(Of KeyValuePair(Of String, Object)) = Nothing) As Gauge(Of T)

Type Parameters

T

Parameters

name
String

The instrument name. cannot be null.

unit
String

Optional instrument unit of measurements.

description
String

Optional instrument description.

tags
IEnumerable<KeyValuePair<String,Object>>

tags to attach to the Gauge.

Returns

Remarks

Gauge is an Instrument which used to record non-additive values.

Example uses for Gauge: record the room background noise level value when changes occur.

Applies to