Class FileLogListener
A log listener that writes log info to file(s).
NOTE: Applies retain policy. By default keeps log files 7 days old.
public class FileLogListener : LogListener
- Inheritance
-
FileLogListener
- Inherited Members
- Extension Methods
Constructors
FileLogListener(string, string, string, int)
Constructor
public FileLogListener(string Folder = "", string DefaultFileName = "", string ColumnLine = "", int MaxSizeKiloBytes = 512)
Parameters
Properties
Folder
The folder where log files are placed. Defaults to Sys.AppRootDataFolder/Logs
public string Folder { get; }
Property Value
MaxSizeKiloBytes
The max size of a log file in MB. When a file reaches that size, a new one is created. Defaults to 5MB.
public override int MaxSizeKiloBytes { get; set; }
Property Value
Methods
ProcessLog(LogEntry)
Called by the Logger to pass LogInfo to a log listener.
CAUTION: The Logger calls its Listeners asynchronously, that is from inside a thread. Thus Listeners should synchronize the ProcessLogInfo() call. Controls need to check if InvokeRequired.
public override void ProcessLog(LogEntry Entry)
Parameters
EntryLogEntry