2024-01-29 14:39:53 +05:00
|
|
|
using System.IO;
|
|
|
|
using AsbCloudApp.Data;
|
2024-01-31 17:18:02 +05:00
|
|
|
using AsbCloudApp.Requests.ParserOptions;
|
2024-01-29 14:39:53 +05:00
|
|
|
|
2024-03-22 09:37:06 +05:00
|
|
|
namespace AsbCloudApp.Services.Parsers;
|
2024-01-29 14:39:53 +05:00
|
|
|
|
|
|
|
/// <summary>
|
2024-02-01 16:35:29 +05:00
|
|
|
/// Сервис парсинга
|
2024-01-29 14:39:53 +05:00
|
|
|
/// </summary>
|
|
|
|
/// <typeparam name="TDto"></typeparam>
|
2024-03-12 12:01:33 +05:00
|
|
|
/// <typeparam name="TOptions"></typeparam>
|
2024-03-22 09:37:06 +05:00
|
|
|
public interface IParserService<TDto, in TOptions> : IParserService
|
2024-01-29 14:39:53 +05:00
|
|
|
where TDto : class, IId
|
2024-03-12 12:01:33 +05:00
|
|
|
where TOptions : IParserOptionsRequest
|
2024-01-29 14:39:53 +05:00
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Распарсить файл
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="file"></param>
|
|
|
|
/// <param name="options"></param>
|
|
|
|
/// <returns></returns>
|
2024-03-12 12:01:33 +05:00
|
|
|
ParserResultDto<TDto> Parse(Stream file, TOptions options);
|
2024-02-01 16:35:29 +05:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Получение шаблона для заполнения
|
|
|
|
/// </summary>
|
|
|
|
/// <returns></returns>
|
|
|
|
Stream GetTemplateFile();
|
2024-03-22 09:37:06 +05:00
|
|
|
}
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Сервис парсинга
|
|
|
|
/// </summary>
|
|
|
|
public interface IParserService
|
|
|
|
{
|
2024-01-29 14:39:53 +05:00
|
|
|
}
|