Beispiel #1
0
 protected override void DisposeCore()
 {
     if (dbContext != null)
     {
         dbContext.Dispose();
     }
 }
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         db.Dispose();
     }
     base.Dispose(disposing);
 }
        /// <summary>
        /// Database context for Payroll Database
        /// </summary>
        protected virtual void Dispose(bool disposing)
        {
            if (!_disposed)
            {
                if (disposing)
                {
                    if (DbContextTransaction != null)
                    {
                        DbContextTransaction.Dispose();
                    }

                    PayrollContext?.Dispose();
                }
            }
            _disposed = true;
        }
Beispiel #4
0
 public virtual void Dispose()
 {
     context.Dispose();
 }