Пример #1
0
 public DbSet()
 {
     if (Tools.IsTableExisting(typeof(T).Name))
     {
         Tools.CreateTable <T>(Tools.GetDbNameFromFile());
     }
     bilder = new QueryBilder <T>();
 }
 public static DataTable Select <T>(this T Entity)
 {
     return(QueryBilder.QueryList(Entity));
 }
 public static bool Delete <T>(this T data, int id)
 {
     return(QueryBilder.QueryDelete(data, id));
 }
 public static bool Update <T>(this T Entity, int id)
 {
     return(QueryBilder.QueryUpdate(Entity, id));
 }
 public static bool Insert <T>(this T expression, T entity)
 {
     return(QueryBilder.QueryInserter(entity));
 }