Exemplo n.º 1
0
 /// <summary>
 /// Deletes the matching entities from the database table
 /// </summary>
 /// <param name="where">The expression to filter entities. This translates to WHERE clause in SQL</param>
 public static void Delete(Expression <Func <T, bool> > where)
 {
     using (var manager = new DotEntityQueryManager())
     {
         manager.DoDelete(where);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Deletes the entity of type <typeparamref name="T"/> from database
 /// </summary>
 /// <param name="entity">The entity to be deleted</param>
 public static void Delete(T entity)
 {
     using (var manager = new DotEntityQueryManager())
     {
         manager.DoDelete(entity);
     }
 }