• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            posts - 297,  comments - 15,  trackbacks - 0

            應用場景:
                    做了一個client,去和Message Middleware通信,實時獲取消息中間件以topic方式(不是Queue,對Message Middleware來說,Queue是發送一個destination,topic可以發多個)。

                    從實時獲取的角度來說,需要啟一個線程,接收Message Middleware消息,然后做場景需要的處理。創建線程的函數如下所示:
             // for compilers which have it, we should use C RTL function for thread
            // creation instead of Win32 API one because otherwise we will have memory
            // leaks if the thread uses C RTL (and most threads do)
            #if defined(__VISUALC__) || \
                (defined(__BORLANDC__) && (__BORLANDC__ >= 0x500)) || \
                (defined(__GNUG__) && defined(__MSVCRT__))
                typedef unsigned (__stdcall *RtlThreadStart)(void *);

                m_hThread = (HANDLE)_beginthreadex(NULL, 0,
                                                   (RtlThreadStart)
                                                   wxThreadInternal::WinThreadStart,
                                                   thread, CREATE_SUSPENDED,
                                                   (unsigned int *)&m_tid);
            #else // compiler doesn't have _beginthreadex
                m_hThread = ::CreateThread
                              (
                                NULL,                               // default security
                                0,                                  // default stack size
                                (LPTHREAD_START_ROUTINE)            // thread entry point
                                wxThreadInternal::WinThreadStart,   // the function that runs under thread
                                (LPVOID)thread,                     // parameter
                                CREATE_SUSPENDED,                   // flags
                                &m_tid                              // [out] thread id
                              );
            #endif // _beginthreadex/CreateThread
            note: there should be a function definition before these lines.eg:
             DWORD wxThreadInternal::WinThreadStart(wxThread *thread)

            posted on 2008-09-26 09:07 chatler 閱讀(507) 評論(0)  編輯 收藏 引用 所屬分類: OS
            <2009年5月>
            262728293012
            3456789
            10111213141516
            17181920212223
            24252627282930
            31123456

            常用鏈接

            留言簿(10)

            隨筆分類(307)

            隨筆檔案(297)

            algorithm

            Books_Free_Online

            C++

            database

            Linux

            Linux shell

            linux socket

            misce

            • cloudward
            • 感覺這個博客還是不錯,雖然做的東西和我不大相關,覺得看看還是有好處的

            network

            OSS

            • Google Android
            • Android is a software stack for mobile devices that includes an operating system, middleware and key applications. This early look at the Android SDK provides the tools and APIs necessary to begin developing applications on the Android platform using the Java programming language.
            • os161 file list

            overall

            搜索

            •  

            最新評論

            閱讀排行榜

            評論排行榜

            久久露脸国产精品| 性色欲网站人妻丰满中文久久不卡| 国内精品久久人妻互换| 国产亚洲精品美女久久久| 久久国产高清字幕中文| 久久久久久噜噜精品免费直播| 久久福利资源国产精品999| 九九精品99久久久香蕉| 开心久久婷婷综合中文字幕| 欧美喷潮久久久XXXXx| 国产免费久久精品99久久| 亚洲中文字幕久久精品无码喷水| 中文精品久久久久国产网址 | 久久亚洲国产精品五月天婷| 久久精品国产99久久久古代| 伊人久久综在合线亚洲2019| 久久精品中文无码资源站| 亚洲国产成人久久一区久久 | 成人国内精品久久久久影院VR| 亚洲欧美另类日本久久国产真实乱对白| 精品久久8x国产免费观看| 亚洲伊人久久成综合人影院| 久久香蕉综合色一综合色88| 久久综合狠狠综合久久综合88| 亚洲国产精品无码久久青草 | 久久亚洲精品国产精品| 色综合久久天天综线观看| 亚洲级αV无码毛片久久精品| 亚洲国产二区三区久久| 国内精品九九久久久精品| 欧美牲交A欧牲交aⅴ久久| 国产A三级久久精品| 久久久久久精品免费看SSS| 精品久久久久久无码不卡| 久久久中文字幕日本| 欧美性大战久久久久久| 久久久久人妻一区精品| 国产巨作麻豆欧美亚洲综合久久| 国产免费福利体检区久久| 国产亚洲精久久久久久无码AV| 91性高湖久久久久|