/// <summary> /// Called whenever an event has been written by an event source for which the /// event listener has enabled events. /// </summary> protected override void OnEventWritten(EventWrittenEventArgs eventData) { if (eventData.EventId == 10 && // TASKWAITBEGIN_ID eventData.Payload != null && eventData.Payload.Count > 3 && eventData.Payload[3] is int value && // Behavior value == 1) // TaskWaitBehavior.Synchronous { OnDetection?.Invoke(this, Environment.StackTrace); } }
public void __Detect__(string err, ObjectResult[] results) { OnDetection?.Invoke(err, results); }
public async Task __Detect__(string err, ObjectResult[] results) #pragma warning restore CS1998 // Async method lacks 'await' operators and will run synchronously { OnDetection?.Invoke(err, results); }