private void Dispose(bool disposing) { if (!disposing) { return; } DisposeBusinessObject(_userBusiness); DisposeBusinessObject(_attendancesBusiness); DisposeBusinessObject(_coursesBusiness); DisposeBusinessObject(_departmentBusiness); DisposeBusinessObject(_facultyBusiness); DisposeBusinessObject(_groupBusiness); DisposeBusinessObject(_studentCourseBusiness); DisposeBusinessObject(_studentsBusiness); DisposeBusinessObject(_teachersBusiness); DisposeBusinessObject(_typesBusiness); DisposeBusinessObject(_reportsBusiness); if (_dalContext != null) { _dalContext.Dispose(); _dalContext = null; } }
protected override void Dispose(bool disposing) { if (disposing) { db.Dispose(); } base.Dispose(disposing); }