using System;
using System.Threading.Tasks;
using Valg.EVA.Skanning.Contracts.CommonEnums;

namespace Valg.EVA.Skanning.Repositories.Transfers
{
    public interface ITransferWriteableRepository
    {
        Task<int> InsertTransferAsync(int transferJobId, TransferState state, string createdBy, byte[] dataPackage);
        Task SetTransferSuccessfulAsync(int transferId, string updatedBy, long fileId);
        int InsertTransferJob(int countingId, string createdBy);
        Task UpdateTransferStateAsync(TransferState transferState, DateTime lastUpdated, TransferState lastTransferState, int transferId, string updatedBy);
        Task SetTransferStateFailedAsync(int transferId, string errorCode, string updatedBy, DateTime? optionalConcurrencyToken);
        Task RefreshUpdatedTimestampOnTransfer(int transferId, string updatedBy, DateTime lastUpdated);
    }
}
