import { BackupShare } from '../entities/backup-share.entity';

export const BACKUP_SHARE_REPOSITORY = Symbol('BACKUP_SHARE_REPOSITORY');

export interface BackupShareRepository {
  save(share: BackupShare): Promise<BackupShare>;
  findById(shareId: bigint): Promise<BackupShare | null>;
  findByUserId(userId: bigint): Promise<BackupShare | null>;
  findByPublicKey(publicKey: string): Promise<BackupShare | null>;
  findByUserIdAndPublicKey(
    userId: bigint,
    publicKey: string,
  ): Promise<BackupShare | null>;
  findByAccountSequence(accountSequence: string): Promise<BackupShare | null>;
  delete(shareId: bigint): Promise<void>;
}
