Early Preview
This is currently very much a preview. Please feel free to try things out,
but don't be upset if anything is not yet working. Feedback is welcome over on our
GitHub Dicussions page.
class System.​Diagnostics.​Tracing.​DiagnosticCounter
Assembly: System.Diagnostics.Tracing
Inheritance: object → DiagnosticCounter
<see cref="T:System.Diagnostics.Tracing.DiagnosticCounter" /> is an abstract class that serves as the parent class for various Counter* classes, namely <see cref="T:System.Diagnostics.Tracing.EventCounter" /> , <see cref="T:System.Diagnostics.Tracing.PollingCounter" /> , <see cref="T:System.Diagnostics.Tracing.IncrementingEventCounter" /> , and <see cref="T:System.Diagnostics.Tracing.IncrementingPollingCounter" /> .
Properties
public
string
DisplayName
Gets or sets the display name of the counter.
public
string
DisplayUnits
Gets or sets the display units of the counter.
public
EventSource
EventSource
Gets the EventSource that this counter is attached to.
public
string
Name
Gets the name of this counter.
Methods
public
void
AddMetadata​(string key,
string value)
key
The metadata key.
value
The metadata value.
Adds key-value metadata to the counter that will be included as a part of the payload.
public
void
Dispose​()
Removes the counter from the set that the <see cref="T:System.Diagnostics.Tracing.EventSource" /> will report on.
public
bool
Equals​(object obj)
Inherited from object
protected
void
Finalize​()
Inherited from object
public
int
GetHashCode​()
Inherited from object
protected
object
MemberwiseClone​()
Inherited from object
public
string
ToString​()
Inherited from object