Update MD2
This commit is contained in:
@@ -0,0 +1,61 @@
|
||||
using Church.Net.Entity.Interface;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Net.NetworkInformation;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Church.Net.DAL.EFCoreDBF.Interface
|
||||
{
|
||||
public interface ICrudDAL<T> where T : class, IEntity
|
||||
{
|
||||
IQueryable<T> GetDbSet();
|
||||
T First(Func<T, bool> filter = null);
|
||||
|
||||
T GetById(string Id);
|
||||
IEnumerable<T> GetAll(Func<T, bool> filter = null);
|
||||
//IEnumerable<T> GetAllById(IEnumerable<string> Ids);
|
||||
int Create(T entity);
|
||||
Task<int> CreateAsync(T entity);
|
||||
|
||||
int CreateOrUpdate(T entity);
|
||||
int Update(T entity);
|
||||
void CreateDone(T entity);
|
||||
void UpdateDone(T entity);
|
||||
|
||||
int UpdateRange(IEnumerable<T> entities);
|
||||
|
||||
int Delete(T obj);
|
||||
int Delete(Func<T, bool> filter);
|
||||
|
||||
bool CheckExist(T obj);
|
||||
IEnumerable<T> GetAllById(IEnumerable<string> Ids);
|
||||
}
|
||||
|
||||
|
||||
public interface ICombinedKeyCrudDAL<T> where T : class
|
||||
{
|
||||
IQueryable<T> GetDbSet();
|
||||
T First(Func<T, bool> filter = null);
|
||||
|
||||
T GetById(IEnumerable<string> combinedKeyIds);
|
||||
IEnumerable<T> GetAll(Func<T, bool> filter = null);
|
||||
int Create(T entity);
|
||||
Task<int> CreateAsync(T entity);
|
||||
int CreateOrUpdate(T entity);
|
||||
int Update(T entity);
|
||||
void CreateDone(T entity);
|
||||
void UpdateDone(T entity);
|
||||
|
||||
int UpdateRange(IEnumerable<T> entities);
|
||||
|
||||
int Delete(T obj);
|
||||
int Delete(IEnumerable<string> combinedKeyIds);
|
||||
int Delete(Func<T, bool> filter);
|
||||
|
||||
bool CheckExist(T obj);
|
||||
IQueryable<T> GetQuery(Func<T, bool> filter = null);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user