示例#1
0
 public void Dispose()
 {
     if (_EmployeeRepository != null)
     {
         _EmployeeRepository.Dispose();
     }
     if (_JobRepository != null)
     {
         _JobRepository.Dispose();
     }
     if (_CustomerRepository != null)
     {
         _CustomerRepository.Dispose();
     }
     if (_DepartmentRepository != null)
     {
         _DepartmentRepository.Dispose();
     }
     if (_FocalPointRepository != null)
     {
         _FocalPointRepository.Dispose();
     }
     if (_ProjectTypeRepository != null)
     {
         _ProjectTypeRepository.Dispose();
     }
     if (_TechnologyRepository != null)
     {
         _TechnologyRepository.Dispose();
     }
     if (_ProjectRepository != null)
     {
         _ProjectRepository.Dispose();
     }
     if (_ProjectTechnologyRepository != null)
     {
         _ProjectTechnologyRepository.Dispose();
     }
     if (_ExperienceRepository != null)
     {
         _ExperienceRepository.Dispose();
     }
     if (_ExperienceTechnologyRepository != null)
     {
         _ExperienceTechnologyRepository.Dispose();
     }
     if (_CompanyRepository != null)
     {
         _CompanyRepository.Dispose();
     }
     if (_UserRepository != null)
     {
         _UserRepository.Dispose();
     }
     if (_RoleRepository != null)
     {
         _RoleRepository.Dispose();
     }
 }
示例#2
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         db.Dispose();
     }
     base.Dispose(disposing);
 }
示例#3
0
 protected virtual void Dispose(bool disposing)
 {
     if (!this.disposed)
     {
         if (disposing)
         {
             deptRepository.Dispose();
         }
     }
     this.disposed = true;
 }
示例#4
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                _disbursementRepo.Dispose();
                _collectionRepo.Dispose();
                _departmentRepo.Dispose();
            }

            base.Dispose(disposing);
        }
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                _employeeRepo.Dispose();
                _delegateRepo.Dispose();
                _departmentRepo.Dispose();
                _requisitionRepo.Dispose();
            }

            base.Dispose(disposing);
        }
示例#6
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                _requisitionRepo.Dispose();
                _disbursementRepo.Dispose();
                _employeeRepo.Dispose();
                _stationeryRepo.Dispose();
                _departmentRepo.Dispose();
                _collectionRepo.Dispose();
                _delegateRepo.Dispose();
            }

            base.Dispose(disposing);
        }
示例#7
0
 private void FormDepartment_OnClose(object sender, EventArgs e)
 {
     dpmRepo.Save();
     dpmRepo.Dispose();
 }