コード例 #1
0
        public void PerformanceTest(object sender, RoutedEventArgs arg)
        {
            GC.Collect();
            var event4 = new Event4()
            {
                Flag = "flag4"
            };
            var sw = Stopwatch.StartNew();

            for (int i = 0; i < 100000; i++)
            {
                LLQNotifier.Default.Notify(event4);
                //subscriber4.Test4();
            }
            sw.Stop();
            rtb.Text = "\r\nNotify: " + sw.Elapsed;

            GC.Collect();
            var event5 = new Event5()
            {
                Flag = "flag5"
            };

            sw = Stopwatch.StartNew();
            for (int i = 0; i < 100000; i++)
            {
                LLQNotifier.Default.Notify(event5);
                //subscriber5.Test5(event5);
            }
            sw.Stop();
            rtb.Text += "\r\nNotify with param: " + sw.Elapsed;
        }
コード例 #2
0
ファイル: MainPage.xaml.cs プロジェクト: brookshi/LLQNotifier
        public void PerformanceTest(object sender, RoutedEventArgs arg)
        {
            GC.Collect();
            var event4 = new Event4() { Flag = "flag4" };
            var sw = Stopwatch.StartNew();
            for (int i=0;i<100000;i++)
            {
                LLQNotifier.Default.Notify(event4);
                //subscriber4.Test4();
            }
            sw.Stop();
            rtb.Text = "\r\nNotify: " + sw.Elapsed;

            GC.Collect();
            var event5 = new Event5() { Flag = "flag5" };
            sw = Stopwatch.StartNew();
            for (int i = 0; i < 100000; i++)
            {
                LLQNotifier.Default.Notify(event5);
                //subscriber5.Test5(event5);
            }
            sw.Stop();
            rtb.Text += "\r\nNotify with param: " + sw.Elapsed;
        }
コード例 #3
0
ファイル: subscriber.cs プロジェクト: trekeagle/LLQNotifier
 public void Test5(Event5 e)
 {
 }
コード例 #4
0
ファイル: subscriber.cs プロジェクト: brookshi/LLQNotifier
 public void Test5(Event5 e)
 {
 }