4 Commits

Author SHA1 Message Date
GwWuYou
3262e111f4 refactor(generator): 重构源代码生成器基础类和诊断功能
- 为 ValidateSymbol 方法添加 Compilation 参数以支持类型解析
- 实现基于 Compilation 的接口类型验证,替代字符串比较方式
- 添加源代码生成器跟踪诊断功能,便于调试生成过程
- 在 AttributeClassGeneratorBase 中增加详细的执行流程跟踪日志
- 更新诊断描述符配置,添加跟踪信息的诊断支持
- 优化 ContextAwareGenerator 中的接口验证逻辑
2025-12-28 16:17:08 +08:00
GwWuYou
414e49c413 refactor(generators): 重构源代码生成器基类架构
- 将 AttributeClassGeneratorBase 抽象基类拆分为 MetadataAttributeClassGeneratorBase 和 TypeAttributeClassGeneratorBase
- 为 GodotLoggerGenerator 实现 TypeAttributeClassGeneratorBase 基类
- 为 EnumExtensionsGenerator 实现 MetadataAttributeClassGeneratorBase 基类
- 为 LoggerGenerator 实现 TypeAttributeClassGeneratorBase 基类
- 为 ContextAwareGenerator 实现 MetadataAttributeClassGeneratorBase 基类
- 添加 ContextAwareGenerator 中对 IContextAware 接口实现的验证逻辑
- 简化 AttributeClassGeneratorBase 中的语法提供程序实现
- 移除 AttributeClassGeneratorBase 中的异常处理和错误输出逻辑
- 优化属性解析机制,使用元数据名称或类型进行特性查找
2025-12-28 16:08:24 +08:00
GwWuYou
e4a317b743 style(generator): 格式化源代码生成器相关文件
- 修复 ILogger.cs 中多余的逗号
- 统一 ContextAwareDiagnostic.cs 中的注释缩进格式
- 统一 ContextAwareGenerator.cs 中的注释缩进格式
- 统一 ContextAwareAttribute.cs 中的注释缩进格式
- 统一 CommonDiagnostics.cs 中的注释缩进格式
- 简化 AttributeClassGeneratorBase.cs 中的 isEnabledByDefault 参数
- 统一 GeneratorTest.cs 中的注释缩进格式
- 优化 ContextAwareGeneratorTests.cs 中的代码结构
- 调整 AnalyzerReleases.Unshipped.md 中的表格格式
2025-12-28 10:50:41 +08:00
GwWuYou
2dea63e69f refactor(abstractions): 将抽象接口迁移至独立项目并更新引用
- 将架构相关接口从 GFramework.Core 迁移至 GFramework.Core.Abstractions 项目
- 更新项目引用配置,添加对抽象层项目的项目引用
- 修正命名空间引用,使用新的抽象层命名空间
- 调整类型定义,将 List<T> 替换为更通用的 IList<T> 接口
- 修复控制器接口命名空间错误
- 添加必要的 using 语句以支持新的抽象层引用
2025-12-28 10:37:18 +08:00