示例#1
0
 public UnitOfWork()
 {
     context = new CMDbContext();
 }
示例#2
0
 /// <summary>
 /// Public Constructor,initializes privately declared local variables.
 /// </summary>
 /// <param name="context"></param>
 public GenericRepository(CMDbContext context)
 {
     this.dbContext = context;
     this.DbSet     = dbContext.Set <TEntity>();
 }