protected override void Dispose(bool disposing) { if (disposing) { db.Dispose(); } base.Dispose(disposing); }
protected virtual void Dispose(bool disposing) { if (!_disposed) { if (disposing) { _ToDoContext.Dispose(); } } _disposed = true; }
public virtual void Dispose(bool disposing) { if (!this.disposed) { if (disposing) { _repository.Dispose(); } } this.disposed = true; }
protected virtual void Dispose(bool disposing) { if (!this.disposed) { if (disposing) { _context.Dispose(); } } this.disposed = true; }
// Protected implementation of Dispose pattern. protected virtual void Dispose(bool disposing) { if (disposed) { return; } if (disposing) { // Free any other managed objects here. // } // Free any unmanaged objects here. if (context != null) { context.Dispose(); } disposed = true; }
public void Dispose() { _context.Dispose(); }
public void Dispose() { _db.Dispose(); GC.SuppressFinalize(this); }
public void Dispose() { _toDoContext?.Dispose(); (_readOnlyToDoContext as IDisposable)?.Dispose(); }