You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
1014 B

using Serilog;
using System;
3 weeks ago
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using TaskManager.Entity;
using TaskManager.EntityFramework.Repository;
using Wood.Util.Filters;
3 weeks ago
namespace TaskManager.EntityFramework
{
public interface IRepository<TEntity> where TEntity : BaseEntity
{
Task<TEntity> GetByIdAsync(long id);
3 weeks ago
Task<IEnumerable<TEntity>> GetAllAsync();
Task<TEntity> AddAsync(TEntity entity);
Task UpdateAsync(TEntity entity);
Task DeleteAsync(long id);
3 weeks ago
Task<PagedResult<TEntity>> GetPagedAsync(PagingParams pagingParams);
Task<PagedResult<TEntity>> GetPagedAsync(
Expression<Func<TEntity, bool>> filter = null,
PagingParams pagingParams = null);
Task<PagedResult<TEntity>> GetDataPagedAsync(
Expression<Func<TEntity, bool>> filter = null,
PagingParams pagingParams = null,Condition condition = null);
3 weeks ago
}
}