public void DoWork() { using (IocDbContext db = _dbContextFactory.CreateContext()) { // use EF here... } }
public UnitOfWork() { _context = new IocDbContext(); }