namespace ServiceBase;

/// <summary>
/// EEMS Client -> EEMS Server
/// </summary>
public interface IClientCaller : IDisposable
{
    Task<Guid> RegisterDevice(DeviceInfo deviceInfo);
    Task<bool> FilePack(Guid guid, byte[] buffer, int current, int total);
    Task<bool> UpdateRealTimeData(Dictionary<string, object> realtimeData);
    Task<bool> UpdateAlarm(IEnumerable<Alarm> alarms);
    Task<bool> UpdateRecipeInfo(Recipe recipeInfo);
}

/// <summary>
/// EEMS Server -> EEMS Client
/// </summary>
public interface IClientProvider
{
    Task<bool> UpdateDeviceInfo(Guid guid, DeviceInfo deviceInfo);
    Task<bool> RequestFile(Guid guid, FileType fileType);
    Task<bool> PushFile(Guid guid, FileType fileType, byte[] buffer, int current, int total);
}