Example #1
0
        private void CollectGarbage_Click(object sender, EventArgs e)
        {
            GC.Collect();

            var sb = new StringBuilder();

            sb.AppendLine();
            sb.Append(GarbageMonitor.Default.State);
            sb.AppendLine();
            sb.Append(ThreadMonitor.ToStringTableString());
            sb.AppendLine();
            sb.Append(AppDomainMonitor.GetCurrentDomainState());
            Log.Trace(sb.ToString());

            ThreadMonitor.Join(0);
        }
        public void Run()
        {
            if (!_updaterStarted)
            {
                MainForm = new MainForm();

                Task.Delay(1000).ContinueWith(task =>
                {
                    Log.Write(LogLevel.Trace, "{0}\r\n{1}", AppDomainMonitor.GetEnvironmentInfo(), AppDomainMonitor.GetCurrentDomainState());
                });

                Application.Run(MainForm);
            }
        }