<PackageReference Include="System.Diagnostics.EventLog" Version="11.0.0" />

System.Diagnostics.Eventing.Reader.EventLogReader

public class EventLogReader : IDisposable
namespace System.Diagnostics.Eventing.Reader { } namespace System.Diagnostics.Eventing.Reader { public class EventLogReader : IDisposable { public int BatchSize { get; set; } public IList<EventLogStatus> LogStatus { get; } public EventLogReader(EventLogQuery eventQuery); public EventLogReader(EventLogQuery eventQuery, EventBookmark bookmark); public EventLogReader(string path); public EventLogReader(string path, PathType pathType); public void CancelReading(); public void Dispose(); protected virtual void Dispose(bool disposing); public EventRecord ReadEvent(); public EventRecord ReadEvent(TimeSpan timeout); public void Seek(EventBookmark bookmark); public void Seek(EventBookmark bookmark, long offset); public void Seek(SeekOrigin origin, long offset); } }