Example #1
0
        static void RunAsInsperctor()
        {
            MyWCF myWCF = new MyWCF();

            myWCF.EventPrint += Write;
            ServiceHost host = myWCF.StartWCFByPipe("127.0.0.1", typeof(Test), typeof(ITest));
        }
Example #2
0
        static void Run()
        {
            MyWCF myWCF = new MyWCF();

            myWCF.EventPrint += Write;
            ServiceHost host = myWCF.StartWCF("127.0.0.1", 6666, typeof(Test), typeof(ITest));

            System.Console.ReadKey();
        }
Example #3
0
        static void RunAsInsperctor()
        {
            MyWCF myWCF   = new MyWCF();
            ITest channel = (ITest)myWCF.GetWcfChannelByPipe <ITest>("127.0.0.1");

            for (int i = 0; i < 10; i++)
            {
                channel.Fun1("Hi:" + i.ToString());
                Thread.Sleep(1000);
            }
        }