LoggingOptions
LoggingOptions
LoggingOptions
LoggingOptions
Class
Definition
Represents advanced event settings.
public : sealed class LoggingOptions : ILoggingOptionspublic sealed class LoggingOptions : ILoggingOptionsPublic NotInheritable Class LoggingOptions Implements ILoggingOptions// You can use this class in JavaScript.
- Attributes
| Device family |
Windows 10 (introduced v10.0.10240.0)
|
| API contract |
Windows.Foundation.UniversalApiContract (introduced v1)
|
Constructors
LoggingOptions() LoggingOptions() LoggingOptions() LoggingOptions()
Initializes a new LoggingOptions instance with default option values.
public : LoggingOptions()public LoggingOptions()Public Sub New()// You can use this method in JavaScript.
- See Also
LoggingOptions(Int64) LoggingOptions(Int64) LoggingOptions(Int64) LoggingOptions(Int64)
Initializes a new LoggingOptions instance with the specified keyword value.
public : LoggingOptions(long keywords)public LoggingOptions(Int64 keywords)Public Sub New(keywords As Int64)// You can use this method in JavaScript.
- keywords
- long Int64 Int64 Int64
The keyword value.
Properties
ActivityId ActivityId ActivityId ActivityId
Gets or sets the unique identifier associated with an activity.
public : PlatForm::Guid ActivityId { get; set; }public Guid ActivityId { get; set; }Public ReadWrite Property ActivityId As Guid// You can use this property in JavaScript.
- Value
- PlatForm::Guid Guid Guid Guid
The activity unique identifier.
Remarks
This value corresponds to the Event Tracing for Windows (ETW) definition of an activity id. You will normally use the LoggingActivity class to automatically manage this value instead of setting it manually.
Keywords Keywords Keywords Keywords
Gets or sets the keyword value that represents the different categories that an event belongs to.
public : long Keywords { get; set; }public long Keywords { get; set; }Public ReadWrite Property Keywords As long// You can use this property in JavaScript.
- Value
- long long long long
The keyword value.
Remarks
Each bit represents a category that an event belongs to. Event Tracing for Windows (ETW) tools are able to filter events based on keyword.
Important
Only the lower 48 bits are available for user-defined event categories. The top eight bits of the keyword value are reserved for future definition and must be set to zero (0). The next eight bits are reserved by Microsoft.
Opcode Opcode Opcode Opcode
Gets or sets the operation code value for an event.
public : LoggingOpcode Opcode { get; set; }public LoggingOpcode Opcode { get; set; }Public ReadWrite Property Opcode As LoggingOpcode// You can use this property in JavaScript.
The operation code.
Remarks
This value corresponds to the Event Tracing for Windows (ETW) definition of an opcode. Most events should use the Info opcode.
The LoggingActivity class will generate events with the Opcode set to Start and Stop.
- See Also
RelatedActivityId RelatedActivityId RelatedActivityId RelatedActivityId
Gets or sets a value that uniquely identifies the parent activity to which this activity is related.
public : PlatForm::Guid RelatedActivityId { get; set; }public Guid RelatedActivityId { get; set; }Public ReadWrite Property RelatedActivityId As Guid// You can use this property in JavaScript.
- Value
- PlatForm::Guid Guid Guid Guid
A value that uniquely identifies the parent activity to which this activity is related.
Remarks
This value corresponds to the Event Tracing for Windows (ETW) definition of a related activity id. You will normally use the LoggingActivity class to automatically manage this value instead of setting it manually.
- See Also
Tags Tags Tags Tags
Gets or sets the user-defined metadata value attached to an event.
public : int Tags { get; set; }public int Tags { get; set; }Public ReadWrite Property Tags As int// You can use this property in JavaScript.
- Value
- int int int int
The tag.
Remarks
The top four bits are reserved and must be set to zero (0).
Up to twenty-eight bits of user-defined information can be attached to an event as metadata. For example, user-defined metadata could be defined to act as instructions to a custom event processing tool to control event sampling, throttling, and so on.
For efficiency reasons, tags should be used for infrequently-changing metadata and not frequently-changing data.
Task Task Task Task
Gets or sets the user-defined value that identifies a larger unit of work within an application or component.
public : short Task { get; set; }public short Task { get; set; }Public ReadWrite Property Task As short// You can use this property in JavaScript.
- Value
- short short short short
The task value.
Remarks
This value corresponds to the Event Tracing for Windows (ETW) definition of a task. It is a user-defined value. A task is a larger unit of work within an application or component, i.e. it identifies a scope of work that is broader than an Opcode.
- See Also