示例#1
0
        static void Main(string[] args)
        {
            //启动解析线程
            MoveProcesser dataProcess = new MoveProcesser();
            Thread m_thread = new Thread(new ThreadStart(dataProcess.Processing));
            m_thread.Start();

            Console.WriteLine("移动服务启动成功!");
            string strLine;
            do
            {
                strLine = Console.ReadLine();
            } while (strLine != null && strLine != "exit");

            Console.WriteLine("移动服务结束...");

            //kill thread
            if (m_thread.IsAlive)
                m_thread.Abort();
        }
示例#2
0
        static void Main(string[] args)
        {
            //启动解析线程
            MoveProcesser dataProcess = new MoveProcesser();
            Thread        m_thread    = new Thread(new ThreadStart(dataProcess.Processing));

            m_thread.Start();

            Console.WriteLine("移动服务启动成功!");
            string strLine;

            do
            {
                strLine = Console.ReadLine();
            } while (strLine != null && strLine != "exit");

            Console.WriteLine("移动服务结束...");

            //kill thread
            if (m_thread.IsAlive)
            {
                m_thread.Abort();
            }
        }