SqlSugar/Src/Asp.Net/SqlSugar/Interface/IDeleteable.cs

42 lines
1.9 KiB
C#
Raw Normal View History

2017-04-30 22:49:41 +08:00
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
namespace SqlSugar
{
2017-05-14 12:59:15 +08:00
public interface IDeleteable<T> where T : class, new()
2017-04-30 22:49:41 +08:00
{
2017-09-05 13:01:10 +08:00
DeleteBuilder DeleteBuilder { get; set; }
2017-04-30 22:49:41 +08:00
int ExecuteCommand();
2017-10-10 15:28:28 +08:00
bool ExecuteCommandHasChange();
2017-09-05 13:01:10 +08:00
Task<int> ExecuteCommandAsync();
2017-10-10 15:28:28 +08:00
Task<bool> ExecuteCommandHasChangeAsync();
2017-05-25 12:39:51 +08:00
IDeleteable<T> AS(string tableName);
2017-05-08 00:26:36 +08:00
IDeleteable<T> With(string lockString);
IDeleteable<T> Where(T deleteObj);
IDeleteable<T> Where(Expression<Func<T, bool>> expression);
IDeleteable<T> Where(List<T> deleteObjs);
2017-05-12 21:11:29 +08:00
IDeleteable<T> In<PkType>(PkType primaryKeyValue);
2017-05-14 12:59:15 +08:00
IDeleteable<T> In<PkType>(PkType[] primaryKeyValues);
2017-05-16 14:00:51 +08:00
IDeleteable<T> In<PkType>(List<PkType> primaryKeyValues);
2018-11-24 16:55:46 +08:00
IDeleteable<T> In<PkType>(Expression<Func<T,object>> inField,PkType primaryKeyValue);
IDeleteable<T> In<PkType>(Expression<Func<T, object>> inField,PkType[] primaryKeyValues);
IDeleteable<T> In<PkType>(Expression<Func<T, object>> inField,List<PkType> primaryKeyValues);
2017-06-22 17:29:53 +08:00
IDeleteable<T> Where(string whereString,object parameters=null);
2017-06-22 21:30:53 +08:00
IDeleteable<T> Where(string whereString, SugarParameter parameter);
IDeleteable<T> Where(string whereString, SugarParameter[] parameters);
IDeleteable<T> Where(string whereString, List<SugarParameter> parameters);
2021-01-28 22:13:36 +08:00
IDeleteable<T> WhereColumns(Expression<Func<T, object>> columns);
IDeleteable<T> Where(List<IConditionalModel> conditionalModels);
2018-11-22 00:36:18 +08:00
IDeleteable<T> EnableDiffLogEvent(object businessData = null);
2017-10-10 19:58:57 +08:00
IDeleteable<T> RemoveDataCache();
2021-03-27 12:35:22 +08:00
IDeleteable<T> RemoveDataCache(string likeString);
2017-05-08 00:33:40 +08:00
KeyValuePair<string, List<SugarParameter>> ToSql();
2021-09-30 00:15:33 +08:00
IDeleteable<T> EnableQueryFilter();
2019-04-04 20:55:21 +08:00
void AddQueue();
2017-04-30 22:49:41 +08:00
}
}