using System.Collections.Generic; using System.Data.Common; using System.Threading; using System.Threading.Tasks; using GB5Shared.GOP.GBQueryExecutor.DTOs; using GB5Shared.DTO.Framework.Criteria; using GB5Shared.DTO.Framework.Login; namespace GB5Shared.GOP.GBQueryExecutor { public interface IGBQueryExecutorDAL { // ── Execution read-only ─────────────────────────────────────── Task GetConfiguredQueryByCode(string queryCode, LoginDTO loginDTO); Task GetConfiguredQueryById(int configuredQueryId, LoginDTO loginDTO); Task GetIntentProfileById(int intentProfileId, LoginDTO loginDTO); Task GetIntentProfileByCode(string intentCode, LoginDTO loginDTO); Task MarkQueryValidated(int configuredQueryId, LoginDTO loginDTO, CancellationToken ct = default); Task LogExecution(GBQueryExecutionLogDTO logDto, LoginDTO loginDTO); // ── Management CRUD ─────────────────────────────────────────── // tx is optional (default null) so BaseEntityAppService.ExecuteSaveAsync // can supply the transaction it opened — existing non-transactional callers are unaffected. Task SaveConfiguredQuery(GBConfiguredQueryDTO dto, LoginDTO loginDTO, DbTransaction? tx = null, CancellationToken ct = default); Task UpdateConfiguredQuery(GBConfiguredQueryDTO dto, LoginDTO loginDTO, DbTransaction? tx = null, CancellationToken ct = default); Task DeleteConfiguredQuery(int configuredQueryId, LoginDTO loginDTO, CancellationToken ct = default); Task> GetConfiguredQueryList(LoginDTO loginDTO, CancellationToken ct = default); Task> GetSelectListIntentProfiles(CriteriaDTO criteriaDTO, LoginDTO loginDTO, CancellationToken ct = default); Task> GetSelectListConfiguredQuery(CriteriaDTO criteriaDTO, LoginDTO loginDTO, CancellationToken ct = default); } }