Example #1
0
 public static void CleanUpMemory()
 {
     AniDB_Anime.GetAll().ForEach(a => a.CollectContractMemory());
     VideoLocal.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeEpisode.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeEpisode_User.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeSeries.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeSeries_User.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeGroup.GetAll().ForEach(a => a.CollectContractMemory());
     AnimeGroup_User.GetAll().ForEach(a => a.CollectContractMemory());
     GC.Collect();
 }
Example #2
0
        public static void CleanUpMemory()
        {
            AniDB_Anime.GetAll().ForEach(a => a.CollectContractMemory());
            VideoLocal.GetAll().ForEach(a => a.CollectContractMemory());
            AnimeEpisode_User.GetAll().ForEach(a => a.CollectContractMemory());
            AnimeSeries.GetAll().ForEach(a => a.CollectContractMemory());
            AnimeSeries_User.GetAll().ForEach(a => a.CollectContractMemory());
            AnimeGroup.GetAll().ForEach(a => a.CollectContractMemory());
            AnimeGroup_User.GetAll().ForEach(a => a.CollectContractMemory());

            GCSettings.LargeObjectHeapCompactionMode = GCLargeObjectHeapCompactionMode.CompactOnce;
            GC.Collect();
        }