import { ReportFile } from '../entities/report-file.entity';
import { OutputFormat } from '../value-objects';

export const REPORT_FILE_REPOSITORY = Symbol('REPORT_FILE_REPOSITORY');

export interface IReportFileRepository {
  save(file: ReportFile): Promise<ReportFile>;
  findById(id: bigint): Promise<ReportFile | null>;
  findBySnapshotId(snapshotId: bigint): Promise<ReportFile[]>;
  findBySnapshotIdAndFormat(
    snapshotId: bigint,
    format: OutputFormat,
  ): Promise<ReportFile | null>;
  findExpired(): Promise<ReportFile[]>;
  deleteExpired(): Promise<number>;
  delete(id: bigint): Promise<void>;
}
