ObservableGauge<T> Class

Definition

ObservableGauge is an observable Instrument that reports non-additive value(s) when the instrument is being observed. e.g. the current room temperature Use Meter.CreateObservableGauge methods to create the observable counter object.

generic <typename T>
 where T : value classpublic ref class ObservableGauge sealed : System::Diagnostics::Metrics::ObservableInstrument<T>
public sealed class ObservableGauge<T> : System.Diagnostics.Metrics.ObservableInstrument<T> where T : struct
type ObservableGauge<'T (requires 'T : struct)> = class
    inherit ObservableInstrument<'T (requires 'T : struct)>
Public NotInheritable Class ObservableGauge(Of T)
Inherits ObservableInstrument(Of T)

Type Parameters

T
Inheritance

Remarks

This class supports only the following generic parameter types: Byte, Int16, Int32, Int64, Single, Double, and Decimal

Properties

Description

Gets the instrument description.

(Inherited from Instrument)
Enabled

Checks if there is any listeners for this instrument.

(Inherited from Instrument)
IsObservable

Gets a value that indicates if the instrument is an observable instrument.

(Inherited from ObservableInstrument<T>)
Meter

Gets the Meter which created the instrument.

(Inherited from Instrument)
Name

Gets the instrument name.

(Inherited from Instrument)
Unit

Gets the instrument unit of measurements.

(Inherited from Instrument)

Methods

Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
Observe()

Fetches the current measurements being tracked by this instrument. All classes extending ObservableInstrument{T} need to implement this method.

(Inherited from ObservableInstrument<T>)
Publish()

Publish is activating the instrument to start recording measurements and to allow listeners to start listening to such measurements.

(Inherited from Instrument)
ToString()

Returns a string that represents the current object.

(Inherited from Object)

Applies to