boost
Hmantic
linux爱好者
展开
-
linxux redhat C++ boost下编译安装
Boost库时一个功能强大、构造精巧、跨平台、开源的C++程序库,下面简单介绍其编译过程。本人使用boost_1.58版本,以下是网盘下载链接:https://pan.baidu.com/s/1F7bJZGFsoJNLSmC357T4cw 提取密码: mvqe1.下载解压 tar -xvf boost_1_58_0.tar.bz22. cd boost_1_58_0 ./bootstrap.s...转载 2018-03-10 14:20:54 · 302 阅读 · 0 评论 -
boost date_time 下 date的使用
通过查看gregrorian目录下可以看到许多关于时间处理的源文件。date_time 库支持无限时间与无效时间等概念。date_time 支持1400-01-01 到9999-12-31之间的日期计算。该库位于命名空间下的grepgorian 中,使用必须包含头文件#include<boost/date_time/gregorian/gregorian.hpp>使用using nam...原创 2018-03-10 15:31:58 · 428 阅读 · 0 评论 -
boost date_time 中 time 运用
(1)时间长度(2)时间长度的精度(3)时间点(4)创建时间点对象(5)操作时间点对象(6)与tm,time_t等结构的转换(7)时间区间(8)时间迭代器(9)综合运用。 需要包含库文件和命名空间#include <boost/date_time/posix_time/posix_time.hpp> using namespace boost::posix_time;相当于在年月日下加...转载 2018-03-10 16:16:23 · 2752 阅读 · 0 评论 -
boost::timer 和progress_timer 使用
1 #include<iostream> 2 #include<boost/timer.hpp> 3 using namespace boost; 4 using namespace std; 5 int main(void) 6 { 7 timer t; 8 9 long long sum = 0; 10 for (i...原创 2018-03-05 20:05:08 · 388 阅读 · 0 评论