Ejemplo n.º 1
0
        static void DebugWorkMode()
        {
            server = new MSConnectionServerTest();
            bool ret = server.BuildServer(Name, (int)numberOfMessages, mode);

            if (ret == false)
            {
                Console.WriteLine("Server Creation error!");
                Environment.Exit(0);
            }
        }
Ejemplo n.º 2
0
        //===============================================================
        static void ServerWorkMode()
        {
            server = new MSConnectionServerTest();
            bool ret = server.BuildServer(Name, (int)numberOfMessages, mode);

            if (ret == false)
            {
                Console.WriteLine("Server Creation error!");
                Environment.Exit(0);
            }
            while (true)
            {
                Console.ForegroundColor = ConsoleColor.Yellow;
                Console.WriteLine("exit - terminate process");
                Console.ForegroundColor = ConsoleColor.White;
                string word = Console.ReadLine();
                if (word == "exit")
                {
                    server.Dispose();
                    Environment.Exit(0);
                }
            }
        }