Beispiel #1
0
        private static void main(string[] args)
        {
            Thread Thread1 = new Thread(new ThreadStart(TheardTest1));

            Thread1.Start();

            Thread Thread2 = new Thread(new ThreadStart(TheardTest2));

            Thread2.Start();

            MetWithoutTracer metWithoutTracer = new MetWithoutTracer(tracer);

            metWithoutTracer.Without();
            Foobar foobar = new Foobar(tracer);

            foobar.FoobarMethod();
            metWithoutTracer.Without();
            metWithoutTracer.Without();

            Thread.Sleep(1000);

            XmlSir     xmlSir     = new XmlSir();
            XmlOutPut  xmlOutPut  = new XmlOutPut();
            JsonSir    jsonSir    = new JsonSir();
            JsonOutPut jsonOutPut = new JsonOutPut();

            xmlOutPut.ConsoleOut(xmlSir.Serialize(tracer.GetTraceResult()));
            jsonOutPut.ConsoleOut(jsonSir.Serialize(tracer.GetTraceResult()));

            xmlOutPut.FileOut(xmlSir.Serialize(tracer.GetTraceResult()), @"test.xml");
            jsonOutPut.FileOut(jsonSir.Serialize(tracer.GetTraceResult()), @"test.txt");
            Console.ReadLine();
        }
Beispiel #2
0
        public static void TheardTest2()
        {
            FooRecTest foorec = new FooRecTest(tracer);

            foorec.FooRec(1);

            Foobar foobar = new Foobar(tracer);

            foobar.FoobarMethod();
        }
Beispiel #3
0
        public static void TheardTest1()
        {
            RecursionTest recursion = new RecursionTest(tracer);

            recursion.Recursion(2);
            Foobar foobar = new Foobar(tracer);

            foobar.FoobarMethod();
            recursion.Recursion(3);
            Bar bar = new Bar(tracer);

            bar.BarMethod();
        }