EventCounter 类
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
提供通过 EventSource 类收集非常频繁事件的统计信息的功能。
public ref class EventCounter : System::Diagnostics::Tracing::DiagnosticCounter
public ref class EventCounter
public ref class EventCounter : IDisposable
C#
public class EventCounter : System.Diagnostics.Tracing.DiagnosticCounter
C#
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
public class EventCounter : System.Diagnostics.Tracing.DiagnosticCounter
C#
public class EventCounter
C#
public class EventCounter : IDisposable
type EventCounter = class
inherit DiagnosticCounter
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
type EventCounter = class
inherit DiagnosticCounter
type EventCounter = class
type EventCounter = class
interface IDisposable
Public Class EventCounter
Inherits DiagnosticCounter
Public Class EventCounter
Public Class EventCounter
Implements IDisposable
- 继承
- 继承
-
EventCounter
- 属性
- 实现
有关如何使用 EventCounter 类的示例,请参阅 简介教程:如何使用 EventCounters 度量非常频繁的事件的性能。
Event |
初始化 EventCounter 类的新实例。 |
Display |
获取或设置计数器的显示名称。 (继承自 DiagnosticCounter) |
Display |
获取或设置计数器的显示单位。 (继承自 DiagnosticCounter) |
Event |
获取此计数器附加到的 EventSource。 (继承自 DiagnosticCounter) |
Name |
获取此计数器的名称。 (继承自 DiagnosticCounter) |
Add |
将键值元数据添加到包含在有效负载中的计数器。 (继承自 DiagnosticCounter) |
Dispose() |
从 EventSource 将报告的集合中删除计数器。 |
Dispose() |
从 EventSource 将报告的集合中删除计数器。 (继承自 DiagnosticCounter) |
Equals(Object) |
确定指定对象是否等于当前对象。 (继承自 Object) |
Get |
作为默认哈希函数。 (继承自 Object) |
Get |
获取当前实例的 Type。 (继承自 Object) |
Memberwise |
创建当前 Object 的浅表副本。 (继承自 Object) |
To |
返回当前事件计数器实例的字符串表示形式。 |
To |
返回表示当前对象的字符串。 (继承自 Object) |
Write |
如果已启用性能计数器,请写入指标。 |
Write |
如果已启用性能计数器,请写入指标。 |
产品 | 版本 |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9 |
.NET Framework | 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 1.5, 1.6, 2.0, 2.1 |