github传送门为:https://nlohmann.github.io/json/简介首先这个库不是奔着性能去的,设计者考虑的是:直观的语法(Intuitive syntax)、微小的整合(Trivial integration)、认真的测试(Serious testing)至于内存效率和速度,反倒不是优先考虑的。先说说微小的整合。在项目中只需要包含一个json.hpp的单个头文件就可以了,为
转载
2023-06-11 13:56:06
138阅读
c++ 11 引入了大量的新特性,这其中包括 语法糖、跨平台通用组件的封装 以及 一些独特的 “新东西”。此系列主要作为本人的个人心得笔记,也作为参考资料,主要罗列 c++ 11 ~ c++ 20的一些特性。 主要参考资料:c++ reference : https://en.cppreference.com/w/
原创
2022-09-23 13:45:01
59阅读
Chapter 1 Deducing Types Item 1: Understand template type deduction. Item 2: Understand auto type deduction. Item 3: Understand decltype. Ite...
转载
2014-12-10 16:53:00
292阅读
Chapter 1 Deducing Types Item Item 3: Understand declt
原创
2023-06-09 16:29:44
94阅读
Variable: The symbolic name of a quantity of data so that the name can be used to access the data it refers to throughout the scope of the code where it is defined. In C++, “variable” is g
原创
2013-01-30 16:02:37
761阅读
C++ library headers <algorithm> <iomanip> <list> <ostream> <streambuf>
原创
2024-06-26 15:52:31
44阅读
有两种对象构造方法,一是在指定内存上构造对象,另一个是先构造一个临时对象,然后把对象拷贝到指定内存上。
原创
2024-07-09 10:39:35
51阅读
tuple 几乎允许所有常用的构造方式:赋值、拷贝、移动,完全可以当做 基本类型使用,不要有任何心理负担。make_tuple 不
原创
2022-09-23 13:34:09
64阅读
在这个模板中,我们不知道我们操纵的容器的类型是什么,那意味着我们同样不知道它使用的索引对象(index objects)的类型,对一个未知类型的对象使用传值通常会造成不必要的拷贝,对程序的性能有极大的影响,还会造成对象切片行为(参见。exp只是一个普通的表达式,它可以是任意复杂的形式,但必须保证exp的结果是有类型的,不能是void;
代码:#include <iostream>#include <
原创
2022-09-23 13:49:12
70阅读
C++ -Standardshttp://open-std.org/JTC1/SC22/WG21/docs/standards
原创
2022-09-23 13:55:31
97阅读
代码片段:std::mutex mut;std::queue<data_chunk> data_queue;std::condition_variable data_cond;void data_preparation_thread(){ wh
原创
2022-09-23 13:35:41
116阅读
用法一:使用可调用对象#include <iostream>#include <thread>#include <Windows.h>using namespace std;template <typen
原创
2022-09-23 13:35:47
173阅读
constexpr 是 c++ 11 引入的关键字,用来在编译阶段运行一些语句和函数,从而在编译阶段就能为常量赋值。如果某些常量的值需要运合运算。
原创
2024-06-13 10:57:59
96阅读
Modern C#系列课程(11):深入“委托和事件” -- LEVEL 300主讲:俞晖 系列:Modern C# 类别:Visual Studio .NET讲座内容:本次课程是系列课程《现代软件开发——使用.NET与C#》的第十一讲(即重开第一讲), 这次系列讲座的目的是为希望从Java, VB6和C++向.NET迁移的程序员提供一个系统的帮助。我们将深入了解委托和事件,从
原创
2007-04-21 14:57:00
29阅读
Metaprogramming library (since C++11) - cppreference.comhttps://en.cppreference.com/w/cpp/meta
原创
2023-12-01 12:21:04
76阅读
Morgan Stanley uses Apache Kafka® to publish market data to internal clients and to persist it for replay purposes. We started out using librdkafka’s
转载
2021-05-15 13:43:00
360阅读
2评论
北京时间2016年1月9日10:31:06。正式開始翻译。水平有限,各位看官若有觉得不妥之处,请批评指正。 之前已经有人翻译了前几个条目,有些借鉴出处:
转载
2017-07-10 14:53:00
125阅读
2评论