コード例 #1
0
 protected override void OnStop()
 {
     try
     {
         log.InfoFormat("OnStop Start", _fileNm);
         //tcpServer.Stop();
         server.Stop();
         log.InfoFormat("OnStop End", _fileNm);
     }
     catch (Exception ex)
     {
         log.ErrorFormat("OnStop: {0}", ex);
     }
 }
コード例 #2
0
        static void Main(string[] args)
        {
            //Tracker.TcpServer.Main tcpServer = new Main();
            //tcpServer.Start();

            ////Console.WriteLine("{0} Protocols are configured", serverTasks.Count);
            //Console.WriteLine("Press [q] to quit the server");

            //do
            //{
            //} while (Console.ReadKey().KeyChar != 'q');

            //tcpServer.Stop();

            //Console.WriteLine("Done");
            //Console.ReadLine();

            server = new TcpServer.TcpServerSAEA.Main();
            server.Start();
            Console.ReadLine();

            server.Stop();
        }
コード例 #3
0
ファイル: Program.cs プロジェクト: madankumar6/CSharp
        static void Main(string[] args)
        {
            //Tracker.TcpServer.Main tcpServer = new Main();
            //tcpServer.Start();

            ////Console.WriteLine("{0} Protocols are configured", serverTasks.Count);
            //Console.WriteLine("Press [q] to quit the server");

            //do
            //{
            //} while (Console.ReadKey().KeyChar != 'q');

            //tcpServer.Stop();

            //Console.WriteLine("Done");
            //Console.ReadLine();

            server = new TcpServer.TcpServerSAEA.Main();
            server.Start();
            Console.ReadLine();

            server.Stop();
        }