First commit
This commit is contained in:
32
Logger/FileLoggerOptions.cs
Normal file
32
Logger/FileLoggerOptions.cs
Normal file
@@ -0,0 +1,32 @@
|
||||
namespace Logger;
|
||||
|
||||
/// <summary>
|
||||
/// Configuration options for file logging
|
||||
/// </summary>
|
||||
public class FileLoggerOptions
|
||||
{
|
||||
/// <summary>
|
||||
/// Name of the log file (without path)
|
||||
/// </summary>
|
||||
public string FileName { get; set; } = "app.log";
|
||||
|
||||
/// <summary>
|
||||
/// Directory where log files are stored
|
||||
/// </summary>
|
||||
public string LogDirectory { get; set; } = "Logs";
|
||||
|
||||
/// <summary>
|
||||
/// Maximum size of a single log file in bytes
|
||||
/// </summary>
|
||||
public long MaxFileSizeBytes { get; set; } = 10 * 1024 * 1024; // 10 MB default
|
||||
|
||||
/// <summary>
|
||||
/// Maximum number of backup log files to keep
|
||||
/// </summary>
|
||||
public int MaxBackupFiles { get; set; } = 5;
|
||||
|
||||
/// <summary>
|
||||
/// Minimum log level to write to file
|
||||
/// </summary>
|
||||
public LogLevel MinimumLevel { get; set; } = LogLevel.Info;
|
||||
}
|
||||
Reference in New Issue
Block a user