摘要:
#pragma oncetemplate <typename T>class PtrData{friend class CSmartPtr<T>;public:explicit PtrData( const T* pT):p_(pT) { count_ = 1; }~PtrData() { delete p_; count_ = 0; }void operator ++ () { ++count_; }void operator -- () { --count_; if (count_ == 0) { delete this; } }T* operator -> 阅读全文
posted @ 2011-01-27 23:02
小 楼 一 夜 听 春 雨
阅读(477)
评论(0)
推荐(0)
摘要:
从http://code.google.com/p/protobuf/上下载protobuf-2.3.0,解压后,打开vsprojects文件夹,然后用VS2005打开protobuf开始编译,然后生成libprotobuf,libprotobuf-lite,libprotoc三个lib,同时生成了 阅读全文
posted @ 2011-01-27 21:08
小 楼 一 夜 听 春 雨
阅读(1961)
评论(0)
推荐(0)

浙公网安备 33010602011771号