using System; using System.Collections.Generic; using System.Linq.Expressions; using System.Text; namespace SlnMesnac.Repository.service.@base { public interface IBaseService where T : class { /// /// 添加实体信息 /// /// /// bool Insert(T model); /// /// 批量添加实体集合 /// /// /// bool Insert(List lisT); /// /// 根据id 删除信息 /// /// /// bool DeleteById(object id); /// /// 根据实体删除信息 /// /// /// bool Delete(T model); /// /// 根据实体集合批量删除信息 /// /// /// bool Deletes(List entitys); /// /// 根据实体更新信息 /// /// /// bool Update(T model); /// /// 批量更新实体集合信息 /// /// /// bool Update(List entitys); /// /// 根据Where条件更新实体信息 /// /// /// /// bool Update(T entity, string strWhere); /// /// 根据实体更新指定列 /// /// /// /// /// /// bool Update(T entity, List lstColumns = null, List lstIgnoreColumns = null, string strWhere = ""); /// /// 查询所有信息 /// /// List Query(); /// /// 根据Id查询实体 /// /// /// T Query(object objId); /// /// 根据表达式查询 /// /// /// List Query(Expression> whereExpression); /// /// 根据表达式排序查询 /// /// 查询条件 /// 排序条件 /// 是否正序 /// List Query(Expression> whereExpression, Expression> orderByExpression, bool isAsc = true); } }