GFramework/GFramework.Core/Logging/AppenderConfiguration.cs
GeWuYou 23489570bf fix(analyzers): 降低 Core、Cqrs、Godot 与生成器的构建警告
- 清理 GFramework.Core 与 GFramework.Cqrs 中的大量低风险 Meziantou 警告

- 修复 GFramework.Godot 运行时中的 ConfigureAwait、StringComparison 与参数校验告警

- 调整 Core SourceGenerators 中的字符串比较、文件命名与局部长方法问题

- 拆分部分配置与缓存辅助类型文件以消除 file/type mismatch 告警

- 更新 warning reduction 跟踪与执行记录,保留下一批结构性告警的恢复点
2026-04-18 16:47:44 +08:00

55 lines
1.5 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using GFramework.Core.Abstractions.Logging;
namespace GFramework.Core.Logging;
/// <summary>
/// Appender 配置。
/// </summary>
public sealed class AppenderConfiguration
{
/// <summary>
/// Appender 类型Console, File, RollingFile, Async
/// </summary>
public string Type { get; set; } = string.Empty;
/// <summary>
/// 格式化器类型Default, Json
/// </summary>
public string Formatter { get; set; } = "Default";
/// <summary>
/// 文件路径(仅用于 File 和 RollingFile
/// </summary>
public string? FilePath { get; set; }
/// <summary>
/// 是否使用颜色(仅用于 Console
/// </summary>
public bool UseColors { get; set; } = true;
/// <summary>
/// 缓冲区大小(仅用于 Async
/// </summary>
public int BufferSize { get; set; } = 10000;
/// <summary>
/// 最大文件大小(仅用于 RollingFile字节
/// </summary>
public long MaxFileSize { get; set; } = 10 * 1024 * 1024;
/// <summary>
/// 最大文件数量(仅用于 RollingFile
/// </summary>
public int MaxFileCount { get; set; } = 5;
/// <summary>
/// 过滤器配置。
/// </summary>
public FilterConfiguration? Filter { get; set; }
/// <summary>
/// 内部 Appender 配置(仅用于 Async
/// </summary>
public AppenderConfiguration? InnerAppender { get; set; }
}