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

            r2100

              C++博客 :: 首頁 :: 聯系 :: 聚合  :: 管理
              8 Posts :: 9 Stories :: 2 Comments :: 0 Trackbacks

            常用鏈接

            留言簿(3)

            我參與的團隊

            搜索

            •  

            最新評論

            閱讀排行榜

            評論排行榜

             1 // boost.cpp : 定義控制臺應用程序的入口點。
             2 //
             3 
             4 #include "stdafx.h"
             5 
             6 #include <iostream>  
             7 #include <boost/thread/thread.hpp>  
             8 #include <boost/bind.hpp>
             9 #include <boost/function.hpp>
            10 void hello(int i, int j)  
            11 {  
            12     std::cout << "Hello world, I'm a thread!" << std::endl;  
            13     std::cout<< i+j << std::endl;
            14 }  
            15 
            16 class A
            17 {
            18 public:
            19     void hello(int i, int j){
            20         std::cout<<i+j<<std::endl;
            21     }
            22 };
            23 
            24 int _tmain(int argc, _TCHAR* argv[])
            25 {
            26     //boost::thread thrd(&hello);  
            27     //thrd.join(); 
            28 // bind
            29 //     A a;
            30 //     boost::bind(&A::hello, a, 1, 2)(1,2);
            31 //     boost::function<void(int,int)> f;
            32 
            33 // function
            34 //     boost::function<void(int,int)> f;
            35 //     f = hello;
            36 //     f(1,2);
            37 
            38     A a;
            39     boost::function<void(A,intint)> cf;
            40     cf=&A::hello;
            41     cf(a,1,2);
            42 
            43 // bind & function    
            44 //     boost::function<void(int,int)> f;
            45 //     f=boost::bind(hello,_1,_2);
            46 //     f(1,1);
            47 // 
            48 //     A a;
            49 //     boost::function<void(int, int)> cf;
            50 //     cf=boost::bind(&A::hello,a,_1,_2);
            51 //     cf(1,1);
            52 // 
            53 //     boost::function<>
            54 
            55     return 0;
            56 }
            57 
            posted on 2015-06-28 23:25 r2100 閱讀(117) 評論(0)  編輯 收藏 引用 所屬分類: C++
            精品久久久久久99人妻| 亚洲国产另类久久久精品小说| 国内精品久久久久影院免费| 色婷婷综合久久久久中文一区二区| 久久精品国产亚洲AV无码娇色| 久久精品国产精品青草| 亚洲性久久久影院| 99久久婷婷国产综合亚洲| 精品久久久无码中文字幕天天| 亚洲人成网站999久久久综合 | 国产成人无码精品久久久久免费 | 日韩乱码人妻无码中文字幕久久 | 亚洲国产精品婷婷久久| 久久综合九色欧美综合狠狠| 久久综合狠狠综合久久综合88| 国内精品欧美久久精品| 中文精品久久久久人妻不卡| 国产精品欧美久久久久天天影视 | 国产精品久久久久9999| 国产精品中文久久久久久久| 精品亚洲综合久久中文字幕| 亚洲欧美日韩精品久久亚洲区 | 久久国产精品99国产精| 日批日出水久久亚洲精品tv| 四虎国产精品免费久久5151| 亚洲AV无一区二区三区久久| 欧美伊人久久大香线蕉综合69| 亚洲综合久久综合激情久久| 亚洲人成精品久久久久| 日韩美女18网站久久精品| 国产精品伦理久久久久久| 久久国产一区二区| 国产91色综合久久免费| 综合人妻久久一区二区精品| 久久精品中文字幕一区| 无码八A片人妻少妇久久| 久久久国产亚洲精品| 伊人久久大香线蕉无码麻豆| 亚洲а∨天堂久久精品| 久久中文字幕视频、最近更新 | 久久久久综合中文字幕|