2021-04-07 18:01:56 +05:00
|
|
|
|
using AsbCloudApp.Data;
|
2021-10-15 15:35:18 +05:00
|
|
|
|
using System;
|
2021-09-29 10:12:54 +05:00
|
|
|
|
using System.Collections.Generic;
|
2021-10-15 12:24:04 +05:00
|
|
|
|
using System.Threading;
|
|
|
|
|
using System.Threading.Tasks;
|
2021-04-07 18:01:56 +05:00
|
|
|
|
|
|
|
|
|
namespace AsbCloudApp.Services
|
|
|
|
|
{
|
|
|
|
|
public interface ITelemetryService
|
|
|
|
|
{
|
2021-11-22 11:30:08 +05:00
|
|
|
|
ITimeZoneService TimeZoneService { get; }
|
2021-11-22 16:02:15 +05:00
|
|
|
|
ITelemetryTracker TelemetryTracker { get; }
|
2021-11-22 11:30:08 +05:00
|
|
|
|
|
2021-12-07 15:55:11 +05:00
|
|
|
|
int? GetIdWellByTelemetryUid(string uid);
|
|
|
|
|
int GetOrCreateTelemetryIdByUid(string uid);
|
2021-06-25 15:10:05 +05:00
|
|
|
|
double GetTimezoneOffsetByTelemetryId(int idTelemetry);
|
2021-11-18 14:25:11 +05:00
|
|
|
|
Task<double?> GetTelemetryTimeZoneOffsetAsync(int idTelemetry, CancellationToken token);
|
2021-12-17 12:48:58 +05:00
|
|
|
|
IEnumerable<TelemetryDto> GetTransmittingTelemetries();
|
|
|
|
|
DateTime GetLastTelemetryDate(string telemetryUid);
|
|
|
|
|
DateTime GetLastTelemetryDate(int telemetryId);
|
|
|
|
|
int? GetIdTelemetryByIdWell(int idWell);
|
2021-12-07 15:55:11 +05:00
|
|
|
|
|
2021-12-17 12:48:58 +05:00
|
|
|
|
Task UpdateInfoAsync(string uid, TelemetryInfoDto info, CancellationToken token);
|
2021-12-24 11:36:20 +05:00
|
|
|
|
Task<DatesRangeDto> DatesRangeToTelemetryTimeZoneAsync(int telemetryId, DatesRangeDto result,
|
2021-12-07 15:55:11 +05:00
|
|
|
|
CancellationToken token);
|
|
|
|
|
|
2021-11-16 13:14:31 +05:00
|
|
|
|
Task UpdateTimeZoneAsync(string uid, TelemetryTimeZoneDto telemetryTimeZoneInfo, CancellationToken token);
|
2021-12-17 12:48:58 +05:00
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Слить данные телеметрии в одну
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="from">старая (исходная)</param>
|
|
|
|
|
/// <param name="to">новая</param>
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
Task<int> MergeAsync(int from, int to, CancellationToken token);
|
|
|
|
|
|
2021-10-28 10:56:18 +05:00
|
|
|
|
void SaveRequestDate(string uid, DateTime remoteDate);
|
2021-04-07 18:01:56 +05:00
|
|
|
|
}
|
2021-12-07 15:55:11 +05:00
|
|
|
|
}
|