• <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++
            亚洲国产天堂久久综合| 无码专区久久综合久中文字幕| 亚洲精品白浆高清久久久久久| 少妇久久久久久被弄高潮| 男女久久久国产一区二区三区| 久久精品国产亚洲AV高清热| 999久久久免费国产精品播放| 无码8090精品久久一区| AV狠狠色丁香婷婷综合久久| 久久久久97国产精华液好用吗| 久久亚洲AV成人无码软件| 久久精品人人做人人爽97| 久久国产精品免费| 久久AV高清无码| 亚洲精品NV久久久久久久久久| 99999久久久久久亚洲| 精品国产日韩久久亚洲| 亚洲国产成人久久精品影视| 日韩人妻无码精品久久久不卡| 久久se精品一区二区影院| 久久久久久亚洲精品成人 | 少妇熟女久久综合网色欲| 久久精品国产亚洲一区二区| 亚洲中文久久精品无码ww16| 国产精品热久久毛片| 国产欧美久久久精品| 日产精品久久久一区二区| 精品久久久久久无码不卡| 久久久国产精品| 久久99热这里只有精品国产| 国产免费久久久久久无码| 久久91精品国产91久久户| 精品久久久久久中文字幕人妻最新| 性做久久久久久免费观看| 亚洲国产综合久久天堂| 理论片午午伦夜理片久久| 亚洲国产精品无码久久青草| 伊人色综合久久天天网| 久久这里只精品99re66| 国产精品成人99久久久久 | 国产午夜福利精品久久|