Ejemplo n.º 1
0
 public static void Borrow(Action <ProoftedDbContext> action)
 {
     using (var context = new ProoftedDbContext())
     {
         action(context);
     }
 }
Ejemplo n.º 2
0
 public static T Borrow <T>(Func <ProoftedDbContext, T> func)
 {
     using (var context = new ProoftedDbContext())
     {
         return(func(context));
     }
 }