This commit is contained in:
SpecialX
2025-06-25 17:21:29 +08:00
parent f9ff57ff72
commit 262e7d6396
21 changed files with 1491 additions and 152 deletions

View File

@@ -9,13 +9,13 @@ namespace TechHelper.Client.Services
{
public class ExamService : IExamService
{
private readonly IAIService _aIService; // 遵循命名规范,字段前加下划线
private readonly HttpClient _client; // 直接注入 HttpClient
private readonly IAIService _aIService;
private readonly HttpClient _client;
public ExamService(IAIService aIService, HttpClient client) // 修正点:直接注入 HttpClient
public ExamService(IAIService aIService, HttpClient client)
{
_aIService = aIService;
_client = client; // 赋值注入的 HttpClient 实例
_client = client;
}
public ApiResponse ConvertToXML<T>(string xmlContent)