boost

    0熱度

    2回答

    我使用multi_index_container來跟蹤插入順序並執行映射工作(如Java的LinkedMap)。 #include <boost/multi_index_container.hpp> #include <boost/multi_index/member.hpp> #include <boost/multi_index/ordered_index.hpp> #include <

    0熱度

    1回答

    我從https://sourceforge.net/projects/boost/files/boost-binaries/1.65.0/獲得了用於VC++ 2010(boost_1_65_0-msvc-10.0-64.exe)的Boost 64位Windows安裝程序。 項目中的包含和庫路徑設置是正確的。 試圖在x64控制檯項目中使用它會導致幾個生成錯誤 - 我只在這裏使用線程類。這些都是錯誤的

    0熱度

    1回答

    考慮: template<typename T> struct MakeVectorOfType { typedef std::vector<T> type; }; typedef boost::mpl::vector<int, double> TScalarTypes; typedef boost::mpl::transform<TScalarTypes, MakeVect

    1熱度

    1回答

    我試圖將一個字符串映射到函數。該功能應該得到一個const char*中過去了。我很奇怪,爲什麼我不斷收到這 *no match for call to ‘(boost::_bi::bind_t<boost::_bi::unspecified, void (*)(const char*), boost::_bi::list0>) (const char*)’* 我的代碼如下 #include

    1熱度

    1回答

    我想通過一個類構造函數進入ros訂閱功能。是否有可能在主題發佈時調用構造函數? class udpMsg { public: std::string udp; size_t posOfDelim; std::string token; udpMsg(){}; udpMsg(const std_msgs::Strin

    1熱度

    1回答

    我可以編譯boost:stacktrace的所有示例。這裏是我的bash腳本: #!/bin/bash export CXX=~/x-tools/x86_64-unknown-linux-gnu/bin/x86_64-unknown-linux-gnu-g++ export BOOST_INCLUDE=$HOME/x-libs/$($CXX -dumpmachine)/include ex

    0熱度

    1回答

    我需要指定要運行的特定單元測試。當然,在查看文檔後,我查看了Stack Overflow Answers,但都沒有使用夾具。 如何指定一個測試用例來運行,如果我有: BOOST_AUTO_TEST_SUITE(mysuite) struct Fixture { Fixture() { BOOST_TEST_MESSAGE("Setup"); }

    3熱度

    1回答

    我使用boost :: variant進行存儲,一個可能的數據成員是一個大型結構。所以二進制變體的大小至少是這個結構大小。在我的情況下,所有其他成員都非常小​​,如int或double。 爲了避免基本的大布局,有沒有辦法強制boost :: variant將項目存儲爲指針? 當然,我可以使用智能指針來保存的500個字節 這個大結構,但在這種情況下,得到了Methode也將工作作爲指針訪問..這是不

    -1熱度

    1回答

    (我將簡化...) 與45M記錄的一種表,其日益增加。 每天晚上,我必須從一爲nvarchar(最大)字段 替換一張表中,我不得不刪除HTML,CSS標籤,也從日期時間字段轉換格林尼治標準時間UTC(8)。 我與標量函數測試,但它很慢,需要花費很長時間.... 這是做的最好的方法(在性能方面)? 我不需要SQL查詢,只是爲了解釋方式/方法... 謝謝! 精密: 我不得不從商業產品中提取過夜45M記

    0熱度

    1回答

    我有一個XML,我喜歡讀入我的程序,我見過很多exmaples如何閱讀XML使用屬性樹從提升,但是我不能讓它適用於嵌套XML,我有: <?xml version="1.0" encoding="UTF-8"?> <document version="1.3.0"> <chunk> <sensors> <sensor id="0" label="un