Instrument<T> 构造函数

定义

重载

Instrument<T>(Meter, String, String, String)

使用属性计量、名称、说明和单位创建指标检测。

Instrument<T>(Meter, String, String, String, IEnumerable<KeyValuePair<String,Object>>)

使用指定的计量、名称、说明和单位初始化 类的新实例 Instrument<T>

Instrument<T>(Meter, String, String, String)

Source:
Instrument.common.cs
Source:
Instrument.common.cs
Source:
Instrument.common.cs

使用属性计量、名称、说明和单位创建指标检测。

protected:
 Instrument(System::Diagnostics::Metrics::Meter ^ meter, System::String ^ name, System::String ^ unit, System::String ^ description);
protected Instrument (System.Diagnostics.Metrics.Meter meter, string name, string? unit, string? description);
new System.Diagnostics.Metrics.Instrument<'T (requires 'T : struct)> : System.Diagnostics.Metrics.Meter * string * string * string -> System.Diagnostics.Metrics.Instrument<'T (requires 'T : struct)>
Protected Sub New (meter As Meter, name As String, unit As String, description As String)

参数

meter
Meter

创建检测的计量器。

name
String

检测名称。 不能为 null

unit
String

可选的仪表度量单位。

description
String

可选检测说明。

注解

在构造扩展类的对象时,扩展 Instrument{T} 的所有类都必须调用此构造函数。

适用于

Instrument<T>(Meter, String, String, String, IEnumerable<KeyValuePair<String,Object>>)

Source:
Instrument.common.cs
Source:
Instrument.common.cs

使用指定的计量、名称、说明和单位初始化 类的新实例 Instrument<T>

protected:
 Instrument(System::Diagnostics::Metrics::Meter ^ meter, System::String ^ name, System::String ^ unit, System::String ^ description, System::Collections::Generic::IEnumerable<System::Collections::Generic::KeyValuePair<System::String ^, System::Object ^>> ^ tags);
protected Instrument (System.Diagnostics.Metrics.Meter meter, string name, string? unit, string? description, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string,object?>>? tags);
new System.Diagnostics.Metrics.Instrument<'T (requires 'T : struct)> : System.Diagnostics.Metrics.Meter * string * string * string * seq<System.Collections.Generic.KeyValuePair<string, obj>> -> System.Diagnostics.Metrics.Instrument<'T (requires 'T : struct)>
Protected Sub New (meter As Meter, name As String, unit As String, description As String, tags As IEnumerable(Of KeyValuePair(Of String, Object)))

参数

meter
Meter

创建检测的计量器。

name
String

检测名称。 不能为 null

unit
String

可选的仪表度量单位。

description
String

可选的仪器说明。

tags
IEnumerable<KeyValuePair<String,Object>>

可选检测标记。

注解

所有扩展 Instrument<T> 类在构造扩展类的对象时都需要调用此构造函数。

适用于