• <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>

            kenlistian

            厚積薄發(fā). 勤為槳,思為帆

               :: 首頁 :: 新隨筆 ::  :: 聚合  :: 管理 ::
              73 隨筆 :: 4 文章 :: 22 評論 :: 0 Trackbacks

             采用bind1st和bind2nd的意思,就是把參數(shù)綁定在第一位還是第二位。
            繼承于binary_function 類.
            描述如下
            Class binder1st binds the value to the first argument of the binary function, and binder2nd does the same thing
            for the second argument of the function.

            如下:例子

            struct compare_str :binary_function<ST_DataResult*, char*, bool>
            {
            public:
                bool operator()(ST_DataResult* pDataRet, char* szTypeCode) const
                {
                    return strcmp(pDataRet->sType , szTypeCode) == 0 ? true : false;
                   
                }
            };


            。。。

            char szTypeCode[4] = {'\0'};
            strcpy(szTypeCode, sTypeCode);
            pIt = find_if(m_d_ret_data.begin(), m_d_ret_data.end(),
                    bind2nd(compare_str(), szTypeCode));

            其中把szTypeCode變量傳入到compare_str所定義的第二個參數(shù)位置傳入。
            如果寫成bind1nd, 則是把szTypeCode作為第一個參數(shù)傳入,那么會報錯。
            因?yàn)轭愋筒粚Α?br>

            posted on 2008-07-14 16:56 kenlistian 閱讀(891) 評論(0)  編輯 收藏 引用 所屬分類: cpp
            中文成人无码精品久久久不卡 | 久久亚洲av无码精品浪潮| 国内精品伊人久久久久AV影院| 少妇精品久久久一区二区三区| 国产精品99久久99久久久| 亚洲国产精品久久久久婷婷老年| 久久综合给合综合久久| 7777久久亚洲中文字幕| 久久精品中文字幕有码| 久久精品中文字幕无码绿巨人| 一本久久久久久久| 久久国产精品77777| 伊人久久成人成综合网222| 亚洲狠狠综合久久| 久久天天躁狠狠躁夜夜网站| 久久久久人妻精品一区三寸蜜桃 | 久久精品国产亚洲沈樵| 欧美精品丝袜久久久中文字幕 | 久久久久久久亚洲精品| 久久99国产综合精品女同| 久久夜色撩人精品国产| 欧美久久精品一级c片片| 亚洲va中文字幕无码久久不卡| 国产福利电影一区二区三区久久老子无码午夜伦不 | 久久精品国产精品亜洲毛片| 国产精品无码久久久久久| 久久精品aⅴ无码中文字字幕不卡| 91精品久久久久久无码| 久久青草国产精品一区| 久久亚洲国产成人精品性色| 久久久久久久久久久| 久久久久久国产精品美女| 午夜精品久久久久久| 久久一本综合| 国产精品久久久久a影院| 三级韩国一区久久二区综合 | 9191精品国产免费久久| 麻豆精品久久久一区二区| 久久免费精品视频| 久久se精品一区二区影院| 亚洲精品高清一二区久久|