﻿using EzApp.Core.ActionResult;
using EzApp.Search.Core;
using EzApp.Search.Pagination;
using System;
using System.Collections.Generic;

namespace EzApp.Services.Core
{
    public interface IEzEntityReadService
        <TEntityId,
        TEntityReadDto,
        TEntityFilters>

        where TEntityId : IEquatable<TEntityId>
        where TEntityFilters : IEzEntityFilters<TEntityId>
    {
        IEzObjectActionResult<TEntityReadDto> GetById(TEntityId id);
        IEzObjectActionResult<IEnumerable<TEntityReadDto>> GetAll();
        IEzPaginatedFilteredObjectActionResult<TEntityReadDto, TEntityId> GetMany(IEzPaginatedEntityQuery<TEntityId, TEntityFilters> query);
    }
}
