protected virtual void OnRaiseEvent(EventSourceEventTypeEventArgs eventSourceEventTypeEventArgs) { EventHandler <EventSourceEventTypeEventArgs> raiseEvent = RaiseEvent; if (raiseEvent != null) { raiseEvent(this, eventSourceEventTypeEventArgs); } }
private void HandleEvent(object sender, EventSourceEventTypeEventArgs args) { Console.WriteLine($"Received event at: {DateTime.Now}, Message class is {args.EventClass}, Message is {args.Message}"); }