Class RecentLogSink¶
Namespace: Apogee.Core.Logging
Assembly: Apogee.Core.dll
Keeps the last lines that were logged, in memory: what a crash report shows of the run's end.
public sealed class RecentLogSink : ILogSink
Inheritance¶
Implements¶
Inherited Members¶
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()
Constructors¶
RecentLogSink(int)¶
A sink that keeps the last capacity lines.
public RecentLogSink(int capacity = 200)
Parameters¶
capacity int
Methods¶
Snapshot()¶
The kept lines, the oldest first.
public string[] Snapshot()
Returns¶
string[]
Write(in LogEntry)¶
public void Write(in LogEntry entry)
Parameters¶
entry LogEntry