コード例 #1
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         db.Dispose();
     }
     base.Dispose(disposing);
 }
コード例 #2
0
ファイル: UnitOfWork.cs プロジェクト: GoD0fWaR/MVC.LinkedIn
        public void Dispose()
        {
            #region Hossam
            SkillManager.Dispose();
            CourseManager.Dispose();
            EmploymentTypeManager.Dispose();
            UserPhotoManager.Dispose();
            UserConnectionManager.Dispose();
            #endregion

            #region Nora
            UserProjectManager.Dispose();
            LanguageManager.Dispose();
            UserLanguageManager.Dispose();
            EducationManager.Dispose();
            #endregion

            #region Wafaa
            ExperienceManager.Dispose();
            CountryManager.Dispose();
            CompanyManager.Dispose();
            JobManager.Dispose();
            CertificationManager.Dispose();
            #endregion

            #region Aya
            PostManager.Dispose();
            CommentManager.Dispose();
            ReplyManager.Dispose();
            PostPhotoManager.Dispose();
            CommentPhotoManager.Dispose();
            ReplyPhotoManager.Dispose();
            #endregion

            ApplicationUserManager.Dispose();
            ApplicationRoleManager.Dispose();
            ApplicationSignInManager.Dispose();

            context = null;
        }