Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
json
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
json
Commits
4b316ec5
Unverified
Commit
4b316ec5
authored
Apr 22, 2017
by
Niels Lohmann
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/insert' into develop
parents
42b4cdd4
9b32f725
Changes
227
Hide whitespace changes
Inline
Side-by-side
Showing
227 changed files
with
387 additions
and
234 deletions
+387
-234
doc/examples/README.cpp
doc/examples/README.cpp
+4
-2
doc/examples/README.link
doc/examples/README.link
+1
-1
doc/examples/README.output
doc/examples/README.output
+1
-1
doc/examples/array.cpp
doc/examples/array.cpp
+1
-1
doc/examples/array.link
doc/examples/array.link
+1
-1
doc/examples/at__object_t_key_type.cpp
doc/examples/at__object_t_key_type.cpp
+1
-1
doc/examples/at__object_t_key_type.link
doc/examples/at__object_t_key_type.link
+1
-1
doc/examples/at__object_t_key_type.test
doc/examples/at__object_t_key_type.test
+0
-3
doc/examples/at__object_t_key_type_const.cpp
doc/examples/at__object_t_key_type_const.cpp
+1
-1
doc/examples/at__object_t_key_type_const.link
doc/examples/at__object_t_key_type_const.link
+1
-1
doc/examples/at__size_type.cpp
doc/examples/at__size_type.cpp
+1
-1
doc/examples/at__size_type.link
doc/examples/at__size_type.link
+1
-1
doc/examples/at__size_type_const.cpp
doc/examples/at__size_type_const.cpp
+1
-1
doc/examples/at__size_type_const.link
doc/examples/at__size_type_const.link
+1
-1
doc/examples/at_json_pointer.cpp
doc/examples/at_json_pointer.cpp
+1
-1
doc/examples/at_json_pointer.link
doc/examples/at_json_pointer.link
+1
-1
doc/examples/at_json_pointer_const.cpp
doc/examples/at_json_pointer_const.cpp
+1
-1
doc/examples/at_json_pointer_const.link
doc/examples/at_json_pointer_const.link
+1
-1
doc/examples/back.cpp
doc/examples/back.cpp
+1
-1
doc/examples/back.link
doc/examples/back.link
+1
-1
doc/examples/basic_json__CompatibleType.cpp
doc/examples/basic_json__CompatibleType.cpp
+1
-1
doc/examples/basic_json__CompatibleType.link
doc/examples/basic_json__CompatibleType.link
+1
-1
doc/examples/basic_json__InputIt_InputIt.cpp
doc/examples/basic_json__InputIt_InputIt.cpp
+1
-1
doc/examples/basic_json__InputIt_InputIt.link
doc/examples/basic_json__InputIt_InputIt.link
+1
-1
doc/examples/basic_json__basic_json.cpp
doc/examples/basic_json__basic_json.cpp
+1
-1
doc/examples/basic_json__basic_json.link
doc/examples/basic_json__basic_json.link
+1
-1
doc/examples/basic_json__copyassignment.cpp
doc/examples/basic_json__copyassignment.cpp
+1
-1
doc/examples/basic_json__copyassignment.link
doc/examples/basic_json__copyassignment.link
+1
-1
doc/examples/basic_json__list_init_t.cpp
doc/examples/basic_json__list_init_t.cpp
+1
-1
doc/examples/basic_json__list_init_t.link
doc/examples/basic_json__list_init_t.link
+1
-1
doc/examples/basic_json__moveconstructor.cpp
doc/examples/basic_json__moveconstructor.cpp
+1
-1
doc/examples/basic_json__moveconstructor.link
doc/examples/basic_json__moveconstructor.link
+1
-1
doc/examples/basic_json__nullptr_t.cpp
doc/examples/basic_json__nullptr_t.cpp
+1
-1
doc/examples/basic_json__nullptr_t.link
doc/examples/basic_json__nullptr_t.link
+1
-1
doc/examples/basic_json__size_type_basic_json.cpp
doc/examples/basic_json__size_type_basic_json.cpp
+1
-1
doc/examples/basic_json__size_type_basic_json.link
doc/examples/basic_json__size_type_basic_json.link
+1
-1
doc/examples/basic_json__value.cpp
doc/examples/basic_json__value.cpp
+1
-1
doc/examples/basic_json__value.link
doc/examples/basic_json__value.link
+1
-1
doc/examples/basic_json__value_ptr.cpp
doc/examples/basic_json__value_ptr.cpp
+1
-1
doc/examples/basic_json__value_ptr.link
doc/examples/basic_json__value_ptr.link
+1
-1
doc/examples/basic_json__value_t.cpp
doc/examples/basic_json__value_t.cpp
+1
-1
doc/examples/basic_json__value_t.link
doc/examples/basic_json__value_t.link
+1
-1
doc/examples/begin.cpp
doc/examples/begin.cpp
+1
-1
doc/examples/begin.link
doc/examples/begin.link
+1
-1
doc/examples/cbegin.cpp
doc/examples/cbegin.cpp
+1
-1
doc/examples/cbegin.link
doc/examples/cbegin.link
+1
-1
doc/examples/cend.cpp
doc/examples/cend.cpp
+1
-1
doc/examples/cend.link
doc/examples/cend.link
+1
-1
doc/examples/clear.cpp
doc/examples/clear.cpp
+1
-1
doc/examples/clear.link
doc/examples/clear.link
+1
-1
doc/examples/count.cpp
doc/examples/count.cpp
+1
-1
doc/examples/count.link
doc/examples/count.link
+1
-1
doc/examples/crbegin.cpp
doc/examples/crbegin.cpp
+1
-1
doc/examples/crbegin.link
doc/examples/crbegin.link
+1
-1
doc/examples/crend.cpp
doc/examples/crend.cpp
+1
-1
doc/examples/crend.link
doc/examples/crend.link
+1
-1
doc/examples/diff.cpp
doc/examples/diff.cpp
+2
-1
doc/examples/diff.link
doc/examples/diff.link
+1
-1
doc/examples/dump.cpp
doc/examples/dump.cpp
+1
-1
doc/examples/dump.link
doc/examples/dump.link
+1
-1
doc/examples/emplace.cpp
doc/examples/emplace.cpp
+1
-1
doc/examples/emplace.link
doc/examples/emplace.link
+1
-1
doc/examples/emplace_back.cpp
doc/examples/emplace_back.cpp
+1
-1
doc/examples/emplace_back.link
doc/examples/emplace_back.link
+1
-1
doc/examples/empty.cpp
doc/examples/empty.cpp
+1
-1
doc/examples/empty.link
doc/examples/empty.link
+1
-1
doc/examples/end.cpp
doc/examples/end.cpp
+1
-1
doc/examples/end.link
doc/examples/end.link
+1
-1
doc/examples/erase__IteratorType.cpp
doc/examples/erase__IteratorType.cpp
+1
-1
doc/examples/erase__IteratorType.link
doc/examples/erase__IteratorType.link
+1
-1
doc/examples/erase__IteratorType_IteratorType.cpp
doc/examples/erase__IteratorType_IteratorType.cpp
+1
-1
doc/examples/erase__IteratorType_IteratorType.link
doc/examples/erase__IteratorType_IteratorType.link
+1
-1
doc/examples/erase__key_type.cpp
doc/examples/erase__key_type.cpp
+1
-1
doc/examples/erase__key_type.link
doc/examples/erase__key_type.link
+1
-1
doc/examples/erase__size_type.cpp
doc/examples/erase__size_type.cpp
+1
-1
doc/examples/erase__size_type.link
doc/examples/erase__size_type.link
+1
-1
doc/examples/find__key_type.cpp
doc/examples/find__key_type.cpp
+1
-1
doc/examples/find__key_type.link
doc/examples/find__key_type.link
+1
-1
doc/examples/flatten.cpp
doc/examples/flatten.cpp
+2
-1
doc/examples/flatten.link
doc/examples/flatten.link
+1
-1
doc/examples/from_cbor.cpp
doc/examples/from_cbor.cpp
+2
-1
doc/examples/from_cbor.link
doc/examples/from_cbor.link
+1
-1
doc/examples/from_msgpack.cpp
doc/examples/from_msgpack.cpp
+2
-1
doc/examples/from_msgpack.link
doc/examples/from_msgpack.link
+1
-1
doc/examples/front.cpp
doc/examples/front.cpp
+1
-1
doc/examples/front.link
doc/examples/front.link
+1
-1
doc/examples/get__PointerType.cpp
doc/examples/get__PointerType.cpp
+1
-1
doc/examples/get__PointerType.link
doc/examples/get__PointerType.link
+1
-1
doc/examples/get__ValueType_const.cpp
doc/examples/get__ValueType_const.cpp
+1
-1
doc/examples/get__ValueType_const.link
doc/examples/get__ValueType_const.link
+1
-1
doc/examples/get_ptr.cpp
doc/examples/get_ptr.cpp
+1
-1
doc/examples/get_ptr.link
doc/examples/get_ptr.link
+1
-1
doc/examples/get_ref.cpp
doc/examples/get_ref.cpp
+1
-1
doc/examples/get_ref.link
doc/examples/get_ref.link
+1
-1
doc/examples/get_ref.test
doc/examples/get_ref.test
+0
-2
doc/examples/insert.cpp
doc/examples/insert.cpp
+1
-1
doc/examples/insert.link
doc/examples/insert.link
+1
-1
doc/examples/insert__count.cpp
doc/examples/insert__count.cpp
+1
-1
doc/examples/insert__count.link
doc/examples/insert__count.link
+1
-1
doc/examples/insert__ilist.cpp
doc/examples/insert__ilist.cpp
+1
-1
doc/examples/insert__ilist.link
doc/examples/insert__ilist.link
+1
-1
doc/examples/insert__range.cpp
doc/examples/insert__range.cpp
+1
-1
doc/examples/insert__range.link
doc/examples/insert__range.link
+1
-1
doc/examples/insert__range_object.cpp
doc/examples/insert__range_object.cpp
+20
-0
doc/examples/insert__range_object.link
doc/examples/insert__range_object.link
+1
-0
doc/examples/insert__range_object.output
doc/examples/insert__range_object.output
+3
-0
doc/examples/is_array.cpp
doc/examples/is_array.cpp
+1
-1
doc/examples/is_array.link
doc/examples/is_array.link
+1
-1
doc/examples/is_boolean.cpp
doc/examples/is_boolean.cpp
+1
-1
doc/examples/is_boolean.link
doc/examples/is_boolean.link
+1
-1
doc/examples/is_discarded.cpp
doc/examples/is_discarded.cpp
+1
-1
doc/examples/is_discarded.link
doc/examples/is_discarded.link
+1
-1
doc/examples/is_null.cpp
doc/examples/is_null.cpp
+1
-1
doc/examples/is_null.link
doc/examples/is_null.link
+1
-1
doc/examples/is_number.cpp
doc/examples/is_number.cpp
+1
-1
doc/examples/is_number.link
doc/examples/is_number.link
+1
-1
doc/examples/is_number_float.cpp
doc/examples/is_number_float.cpp
+1
-1
doc/examples/is_number_float.link
doc/examples/is_number_float.link
+1
-1
doc/examples/is_number_integer.cpp
doc/examples/is_number_integer.cpp
+1
-1
doc/examples/is_number_integer.link
doc/examples/is_number_integer.link
+1
-1
doc/examples/is_number_unsigned.cpp
doc/examples/is_number_unsigned.cpp
+1
-1
doc/examples/is_number_unsigned.link
doc/examples/is_number_unsigned.link
+1
-1
doc/examples/is_object.cpp
doc/examples/is_object.cpp
+1
-1
doc/examples/is_object.link
doc/examples/is_object.link
+1
-1
doc/examples/is_primitive.cpp
doc/examples/is_primitive.cpp
+1
-1
doc/examples/is_primitive.link
doc/examples/is_primitive.link
+1
-1
doc/examples/is_string.cpp
doc/examples/is_string.cpp
+1
-1
doc/examples/is_string.link
doc/examples/is_string.link
+1
-1
doc/examples/is_structured.cpp
doc/examples/is_structured.cpp
+1
-1
doc/examples/is_structured.link
doc/examples/is_structured.link
+1
-1
doc/examples/json_pointer.cpp
doc/examples/json_pointer.cpp
+1
-1
doc/examples/json_pointer.link
doc/examples/json_pointer.link
+1
-1
doc/examples/json_pointer.test
doc/examples/json_pointer.test
+0
-3
doc/examples/json_pointer__to_string.cpp
doc/examples/json_pointer__to_string.cpp
+1
-1
doc/examples/json_pointer__to_string.link
doc/examples/json_pointer__to_string.link
+1
-1
doc/examples/max_size.cpp
doc/examples/max_size.cpp
+1
-1
doc/examples/max_size.link
doc/examples/max_size.link
+1
-1
doc/examples/meta.cpp
doc/examples/meta.cpp
+2
-1
doc/examples/meta.link
doc/examples/meta.link
+1
-1
doc/examples/meta.output
doc/examples/meta.output
+1
-1
doc/examples/object.cpp
doc/examples/object.cpp
+1
-1
doc/examples/object.link
doc/examples/object.link
+1
-1
doc/examples/operator__ValueType.cpp
doc/examples/operator__ValueType.cpp
+1
-1
doc/examples/operator__ValueType.link
doc/examples/operator__ValueType.link
+1
-1
doc/examples/operator__equal.cpp
doc/examples/operator__equal.cpp
+1
-1
doc/examples/operator__equal.link
doc/examples/operator__equal.link
+1
-1
doc/examples/operator__equal.output
doc/examples/operator__equal.output
+1
-1
doc/examples/operator__equal.test
doc/examples/operator__equal.test
+0
-4
doc/examples/operator__equal__nullptr_t.cpp
doc/examples/operator__equal__nullptr_t.cpp
+1
-1
doc/examples/operator__equal__nullptr_t.link
doc/examples/operator__equal__nullptr_t.link
+1
-1
doc/examples/operator__greater.cpp
doc/examples/operator__greater.cpp
+1
-1
doc/examples/operator__greater.link
doc/examples/operator__greater.link
+1
-1
doc/examples/operator__greaterequal.cpp
doc/examples/operator__greaterequal.cpp
+1
-1
doc/examples/operator__greaterequal.link
doc/examples/operator__greaterequal.link
+1
-1
doc/examples/operator__less.cpp
doc/examples/operator__less.cpp
+1
-1
doc/examples/operator__less.link
doc/examples/operator__less.link
+1
-1
doc/examples/operator__lessequal.cpp
doc/examples/operator__lessequal.cpp
+1
-1
doc/examples/operator__lessequal.link
doc/examples/operator__lessequal.link
+1
-1
doc/examples/operator__notequal.cpp
doc/examples/operator__notequal.cpp
+1
-1
doc/examples/operator__notequal.link
doc/examples/operator__notequal.link
+1
-1
doc/examples/operator__notequal.output
doc/examples/operator__notequal.output
+1
-1
doc/examples/operator__notequal.test
doc/examples/operator__notequal.test
+0
-4
doc/examples/operator__notequal__nullptr_t.cpp
doc/examples/operator__notequal__nullptr_t.cpp
+1
-1
doc/examples/operator__notequal__nullptr_t.link
doc/examples/operator__notequal__nullptr_t.link
+1
-1
doc/examples/operator__value_t.cpp
doc/examples/operator__value_t.cpp
+1
-1
doc/examples/operator__value_t.link
doc/examples/operator__value_t.link
+1
-1
doc/examples/operator_deserialize.cpp
doc/examples/operator_deserialize.cpp
+2
-1
doc/examples/operator_deserialize.link
doc/examples/operator_deserialize.link
+1
-1
doc/examples/operator_serialize.cpp
doc/examples/operator_serialize.cpp
+2
-1
doc/examples/operator_serialize.link
doc/examples/operator_serialize.link
+1
-1
doc/examples/operatorarray__key_type.cpp
doc/examples/operatorarray__key_type.cpp
+2
-1
doc/examples/operatorarray__key_type.link
doc/examples/operatorarray__key_type.link
+1
-1
doc/examples/operatorarray__key_type_const.cpp
doc/examples/operatorarray__key_type_const.cpp
+1
-1
doc/examples/operatorarray__key_type_const.link
doc/examples/operatorarray__key_type_const.link
+1
-1
doc/examples/operatorarray__size_type.cpp
doc/examples/operatorarray__size_type.cpp
+1
-1
doc/examples/operatorarray__size_type.link
doc/examples/operatorarray__size_type.link
+1
-1
doc/examples/operatorarray__size_type_const.cpp
doc/examples/operatorarray__size_type_const.cpp
+1
-1
doc/examples/operatorarray__size_type_const.link
doc/examples/operatorarray__size_type_const.link
+1
-1
doc/examples/operatorjson_pointer.cpp
doc/examples/operatorjson_pointer.cpp
+1
-1
doc/examples/operatorjson_pointer.link
doc/examples/operatorjson_pointer.link
+1
-1
doc/examples/operatorjson_pointer_const.cpp
doc/examples/operatorjson_pointer_const.cpp
+1
-1
doc/examples/operatorjson_pointer_const.link
doc/examples/operatorjson_pointer_const.link
+1
-1
doc/examples/parse__array__parser_callback_t.cpp
doc/examples/parse__array__parser_callback_t.cpp
+2
-1
doc/examples/parse__array__parser_callback_t.link
doc/examples/parse__array__parser_callback_t.link
+1
-1
doc/examples/parse__contiguouscontainer__parser_callback_t.cpp
...xamples/parse__contiguouscontainer__parser_callback_t.cpp
+2
-1
doc/examples/parse__contiguouscontainer__parser_callback_t.link
...amples/parse__contiguouscontainer__parser_callback_t.link
+1
-1
doc/examples/parse__istream__parser_callback_t.cpp
doc/examples/parse__istream__parser_callback_t.cpp
+2
-1
doc/examples/parse__istream__parser_callback_t.link
doc/examples/parse__istream__parser_callback_t.link
+1
-1
doc/examples/parse__iteratortype__parser_callback_t.cpp
doc/examples/parse__iteratortype__parser_callback_t.cpp
+2
-1
doc/examples/parse__iteratortype__parser_callback_t.link
doc/examples/parse__iteratortype__parser_callback_t.link
+1
-1
doc/examples/parse__string__parser_callback_t.cpp
doc/examples/parse__string__parser_callback_t.cpp
+2
-1
doc/examples/parse__string__parser_callback_t.link
doc/examples/parse__string__parser_callback_t.link
+1
-1
doc/examples/patch.cpp
doc/examples/patch.cpp
+2
-1
doc/examples/patch.link
doc/examples/patch.link
+1
-1
doc/examples/push_back.cpp
doc/examples/push_back.cpp
+1
-1
doc/examples/push_back.link
doc/examples/push_back.link
+1
-1
doc/examples/push_back__initializer_list.cpp
doc/examples/push_back__initializer_list.cpp
+1
-1
doc/examples/push_back__initializer_list.link
doc/examples/push_back__initializer_list.link
+1
-1
doc/examples/push_back__object_t__value.cpp
doc/examples/push_back__object_t__value.cpp
+1
-1
doc/examples/push_back__object_t__value.link
doc/examples/push_back__object_t__value.link
+1
-1
doc/examples/rbegin.cpp
doc/examples/rbegin.cpp
+1
-1
doc/examples/rbegin.link
doc/examples/rbegin.link
+1
-1
doc/examples/rend.cpp
doc/examples/rend.cpp
+1
-1
doc/examples/rend.link
doc/examples/rend.link
+1
-1
doc/examples/size.cpp
doc/examples/size.cpp
+1
-1
doc/examples/size.link
doc/examples/size.link
+1
-1
doc/examples/swap__array_t.cpp
doc/examples/swap__array_t.cpp
+1
-1
doc/examples/swap__array_t.link
doc/examples/swap__array_t.link
+1
-1
doc/examples/swap__object_t.cpp
doc/examples/swap__object_t.cpp
+1
-1
doc/examples/swap__object_t.link
doc/examples/swap__object_t.link
+1
-1
doc/examples/swap__reference.cpp
doc/examples/swap__reference.cpp
+1
-1
doc/examples/swap__reference.link
doc/examples/swap__reference.link
+1
-1
doc/examples/swap__string_t.cpp
doc/examples/swap__string_t.cpp
+1
-1
doc/examples/swap__string_t.link
doc/examples/swap__string_t.link
+1
-1
doc/examples/to_cbor.cpp
doc/examples/to_cbor.cpp
+2
-1
doc/examples/to_cbor.link
doc/examples/to_cbor.link
+1
-1
doc/examples/to_msgpack.cpp
doc/examples/to_msgpack.cpp
+2
-1
doc/examples/to_msgpack.link
doc/examples/to_msgpack.link
+1
-1
doc/examples/type.cpp
doc/examples/type.cpp
+1
-1
doc/examples/type.link
doc/examples/type.link
+1
-1
doc/examples/type_name.cpp
doc/examples/type_name.cpp
+1
-1
doc/examples/type_name.link
doc/examples/type_name.link
+1
-1
doc/examples/unflatten.cpp
doc/examples/unflatten.cpp
+2
-1
doc/examples/unflatten.link
doc/examples/unflatten.link
+1
-1
src/json.hpp
src/json.hpp
+46
-0
src/json.hpp.re2c
src/json.hpp.re2c
+46
-0
test/src/unit-modifiers.cpp
test/src/unit-modifiers.cpp
+35
-1
No files found.
doc/examples/README.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
@@ -29,7 +30,8 @@ int main()
j
[
"new"
][
"key"
][
"value"
]
=
{
"another"
,
"list"
};
// count elements
j
[
"size"
]
=
j
.
size
();
auto
s
=
j
.
size
();
j
[
"size"
]
=
s
;
// pretty print with indent of 4 spaces
std
::
cout
<<
std
::
setw
(
4
)
<<
j
<<
'\n'
;
...
...
doc/examples/README.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/nv9fOg0XVVhWmFFy"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Mi7u49cYwMR0cgTH"><b>online</b></a>
\ No newline at end of file
doc/examples/README.output
View file @
4b316ec5
...
...
@@ -23,5 +23,5 @@
"value": 42.99
},
"pi": 3.141,
"size":
9
"size":
8
}
doc/examples/array.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/array.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/1fsm4gI55p83DOwU"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/dREyaxnVNgG1CAUx"><b>online</b></a>
\ No newline at end of file
doc/examples/at__object_t_key_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at__object_t_key_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/8ldtT0NOhidn0fOA"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/rCEcfTCRY40LDvoR"><b>online</b></a>
\ No newline at end of file
doc/examples/at__object_t_key_type.test
deleted
100644 → 0
View file @
42b4cdd4
"il brutto"
{
"the bad"
:
"il cattivo"
,
"the good"
:
"il buono"
,
"the ugly"
:
"il brutto"
}
[
json
.
exception
.
out_of_range
.
403
]
key
'the fast'
not
found
doc/examples/at__object_t_key_type_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at__object_t_key_type_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/nfmFWMaJJHFJ7eVK"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/SIuocSXktJ2lxj0q"><b>online</b></a>
\ No newline at end of file
doc/examples/at__size_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at__size_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/8UnQY256zGX2Lx6d"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/wB9tQWAyqeajJTVn"><b>online</b></a>
\ No newline at end of file
doc/examples/at__size_type_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at__size_type_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/U1fv6LY7xZOAuSBs"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/s5MsN3WV6zsGcWY4"><b>online</b></a>
\ No newline at end of file
doc/examples/at_json_pointer.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at_json_pointer.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Fy2xBfZMols2DUQC"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/SXcTwaW8DVzDT34z"><b>online</b></a>
\ No newline at end of file
doc/examples/at_json_pointer_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/at_json_pointer_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/WxhV3mL9YX8FJonk"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/zOTLPM0c5dNFZhk3"><b>online</b></a>
\ No newline at end of file
doc/examples/back.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/back.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/CAv4NNr4D1FJhhUv"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Sco4kIFMzpkYo37h"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__CompatibleType.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
#include <deque>
#include <list>
#include <forward_list>
...
...
doc/examples/basic_json__CompatibleType.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/VM7W2kpE7sIYJ5DW"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/n2KT4Yk3mzZXKnS5"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__InputIt_InputIt.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__InputIt_InputIt.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/oUU2X0pbZq7gawRB"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/gsHOHaLe3MfVhI2s"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__basic_json.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__basic_json.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/6Qfn12BDzb3vqO5p"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/zUmWzPFVFx6sEojX"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__copyassignment.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__copyassignment.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/iWYvmlA4qQmtvACX"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/1BjO38rdSmNGxpyn"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__list_init_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__list_init_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/iZzzxEpB7tbhz0cx"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/H0DDK6yuoCGZuoFw"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__moveconstructor.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__moveconstructor.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/CaDlatv1uXhQiu7o"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/nXd0SKQaR6tHukvy"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__nullptr_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__nullptr_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/9Tvfs2dJBW8m8ihA"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/AbLqRqEEN5N9W1Fj"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__size_type_basic_json.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__size_type_basic_json.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/IFZT4VL0oRotJBxl"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/ecx4xZQX7VXuhlAz"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__value.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__value.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/qdV5W2Lrljmjv4LG"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/bP03yg3IIbhARy2F"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__value_ptr.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__value_ptr.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/K4L4D6nibuGXbjfd"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/OY0l4CpfWuDJudyo"><b>online</b></a>
\ No newline at end of file
doc/examples/basic_json__value_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/basic_json__value_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/RMpEI2o935KgD2o2"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/zRdz49DwtK0gIJuc"><b>online</b></a>
\ No newline at end of file
doc/examples/begin.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/begin.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/0lW1WJ1ZP8g92Jp9"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Q0QcnX1LAQT5k7IU"><b>online</b></a>
\ No newline at end of file
doc/examples/cbegin.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/cbegin.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/yarD6DyxYlIf8Ymg"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/ukuefRRIclE7D7IX"><b>online</b></a>
\ No newline at end of file
doc/examples/cend.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/cend.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/9oPbpnFNgKtKjB0O"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/nHLMXLRwA3QWSnsQ"><b>online</b></a>
\ No newline at end of file
doc/examples/clear.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/clear.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/wwsjMZP8U6bWhUil"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/WQS4WbZC6pX4qZE4"><b>online</b></a>
\ No newline at end of file
doc/examples/count.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/count.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/yv5TMrq9qREivvHf"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/mrJDlTQD3orHnAdF"><b>online</b></a>
\ No newline at end of file
doc/examples/crbegin.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/crbegin.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/GQz9A5y7HduQHVMw"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/XsC14rus4L6meQTg"><b>online</b></a>
\ No newline at end of file
doc/examples/crend.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/crend.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Qom888gs2RM4wR4H"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/jr4aG41Zr1pWUlAw"><b>online</b></a>
\ No newline at end of file
doc/examples/diff.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/diff.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/hicmeOK39tBxaluM"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/KKfCy1yctyq7PBI1"><b>online</b></a>
\ No newline at end of file
doc/examples/dump.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/dump.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/rjYfsEq7v1RCHprk"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/jC8OLyTjE6EOcMZt"><b>online</b></a>
\ No newline at end of file
doc/examples/emplace.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/emplace.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/B6ILaoysGMliouEO"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/mvy0nMn3uStrP9tS"><b>online</b></a>
\ No newline at end of file
doc/examples/emplace_back.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/emplace_back.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/jdch45YEMX94DvlH"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/wvLvTvPt0dovixFE"><b>online</b></a>
\ No newline at end of file
doc/examples/empty.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/empty.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/rP64u8KqUJqB9lFd"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/g1mZBQAdSJE3cNCH"><b>online</b></a>
\ No newline at end of file
doc/examples/end.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/end.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/4Fbmy4IG012HmGKs"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/vp0L5nlCJewdlolt"><b>online</b></a>
\ No newline at end of file
doc/examples/erase__IteratorType.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/erase__IteratorType.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/W83LsQNBy5qCoABq"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/N0oo892iXEqaUzej"><b>online</b></a>
\ No newline at end of file
doc/examples/erase__IteratorType_IteratorType.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/erase__IteratorType_IteratorType.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/zGMngigiwwhsXEhB"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/SO3kgH5glqC18wJy"><b>online</b></a>
\ No newline at end of file
doc/examples/erase__key_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/erase__key_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/0eXbiM5KTPPXFkyP"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/wyOm5ERfxlXcwcSV"><b>online</b></a>
\ No newline at end of file
doc/examples/erase__size_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/erase__size_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/WXGKRKjzP22ggTEr"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/lxSvv5XGZ8Hmhnwl"><b>online</b></a>
\ No newline at end of file
doc/examples/find__key_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/find__key_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Kk6nOpsa6KetydpZ"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/yqzasB01C3NGORaT"><b>online</b></a>
\ No newline at end of file
doc/examples/flatten.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/flatten.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/cdQa6jE0N2LyqFJe"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/qGLscdPoE6QH87oD"><b>online</b></a>
\ No newline at end of file
doc/examples/from_cbor.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/from_cbor.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/TDPaxmQ7PsvfWxrs"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/DUNMc8fjsGi5C7Ea"><b>online</b></a>
\ No newline at end of file
doc/examples/from_msgpack.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/from_msgpack.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/7vRGmLdVcYM7POhE"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/wSkYD6Q5RqJWmt3s"><b>online</b></a>
\ No newline at end of file
doc/examples/front.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/front.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/CUpMCzt6D9v3cYGM"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/fbTQdF5PwEeaC2lq"><b>online</b></a>
\ No newline at end of file
doc/examples/get__PointerType.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/get__PointerType.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/TRkhQoCdScWQqi3x"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/YwRJe95xb68JVjuI"><b>online</b></a>
\ No newline at end of file
doc/examples/get__ValueType_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
#include <unordered_map>
using
json
=
nlohmann
::
json
;
...
...
doc/examples/get__ValueType_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ksZAkIKQnYhJKLpN"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/FeK53w3zimBjOhtB"><b>online</b></a>
\ No newline at end of file
doc/examples/get_ptr.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/get_ptr.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/xYbUV0BmOfNtQcED"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/6DBW0AukFiY85CMq"><b>online</b></a>
\ No newline at end of file
doc/examples/get_ref.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/get_ref.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/lsl8Ex3d3SOYnKHu"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/868NoVK7iU0BZHKz"><b>online</b></a>
\ No newline at end of file
doc/examples/get_ref.test
deleted
100644 → 0
View file @
42b4cdd4
17
17
[
json
.
exception
.
type_error
.
303
]
incompatible
ReferenceType
for
get_ref
,
actual
type
is
number
doc/examples/insert.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/insert.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ePN9gb4P3WTAiT6H"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Af1lyC9TuTbIaNHy"><b>online</b></a>
\ No newline at end of file
doc/examples/insert__count.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/insert__count.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/wnxritIWxpGS2SSt"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/J7tEcc5RiRckp3aH"><b>online</b></a>
\ No newline at end of file
doc/examples/insert__ilist.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/insert__ilist.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/kem0JnkdOVLNHii5"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/qgQADJFErGWzwFS3"><b>online</b></a>
\ No newline at end of file
doc/examples/insert__range.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/insert__range.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/rub1CDmN5dKK1LJW"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/n97dklxei6VGm4nn"><b>online</b></a>
\ No newline at end of file
doc/examples/insert__range_object.cpp
0 → 100644
View file @
4b316ec5
#include "json.hpp"
using
json
=
nlohmann
::
json
;
int
main
()
{
// create two JSON objects
json
j1
=
{{
"one"
,
"eins"
},
{
"two"
,
"zwei"
}};
json
j2
=
{{
"eleven"
,
"elf"
},
{
"seventeen"
,
"siebzehn"
}};
// output objects
std
::
cout
<<
j1
<<
'\n'
;
std
::
cout
<<
j2
<<
'\n'
;
// insert range from j2 to j1
j1
.
insert
(
j2
.
begin
(),
j2
.
end
());
// output result of insert call
std
::
cout
<<
j1
<<
'\n'
;
}
doc/examples/insert__range_object.link
0 → 100644
View file @
4b316ec5
<a target="_blank" href="https://wandbox.org/permlink/lj1jKDLtLmx2v1G0"><b>online</b></a>
\ No newline at end of file
doc/examples/insert__range_object.output
0 → 100644
View file @
4b316ec5
{"one":"eins","two":"zwei"}
{"eleven":"elf","seventeen":"siebzehn"}
{"eleven":"elf","one":"eins","seventeen":"siebzehn","two":"zwei"}
doc/examples/is_array.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_array.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/hGGh0jnNmRo7bYAZ"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/DvtGvyx9zygjT0kS"><b>online</b></a>
\ No newline at end of file
doc/examples/is_boolean.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_boolean.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/tWBJHygekWKqZIqe"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Io4dYYukmsvBsBhZ"><b>online</b></a>
\ No newline at end of file
doc/examples/is_discarded.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_discarded.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/USx0486t9Qxi5LS3"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/sznqCvDTQxq642QL"><b>online</b></a>
\ No newline at end of file
doc/examples/is_null.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_null.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/d75Hu1c8QVdDtabd"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/imhZMfDkB8bFRp7q"><b>online</b></a>
\ No newline at end of file
doc/examples/is_number.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_number.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/97mIrpY9h1rodAfI"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/PMSuHln29jOu8ySo"><b>online</b></a>
\ No newline at end of file
doc/examples/is_number_float.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_number_float.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/AHeVLaVJlG3cIehg"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/jf7HjebGYWYKNMJQ"><b>online</b></a>
\ No newline at end of file
doc/examples/is_number_integer.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_number_integer.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/WRiD854M5bTtQTnw"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/1HGdpuy7JGkt6IZd"><b>online</b></a>
\ No newline at end of file
doc/examples/is_number_unsigned.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_number_unsigned.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/BYzDklHPHDZA2CXX"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/nlZ9nbm8xJjTAsMe"><b>online</b></a>
\ No newline at end of file
doc/examples/is_object.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_object.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/TW8VagDAhVeaItcp"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/5nZW4U1bUA5lem25"><b>online</b></a>
\ No newline at end of file
doc/examples/is_primitive.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_primitive.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/A0B17yXywuT7Z1gx"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/V4emskHeUktlVOxh"><b>online</b></a>
\ No newline at end of file
doc/examples/is_string.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_string.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ePqrJBez1pH5dC7V"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/lb59ps8hvZkRQtly"><b>online</b></a>
\ No newline at end of file
doc/examples/is_structured.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/is_structured.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/46XRsxj3NvcwTpAZ"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/oe0ULeAlBAiaqUxh"><b>online</b></a>
\ No newline at end of file
doc/examples/json_pointer.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/json_pointer.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Wlvqfd3JpEXTv2iH"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/JdZq6bQWjrHew4Dy"><b>online</b></a>
\ No newline at end of file
doc/examples/json_pointer.test
deleted
100644 → 0
View file @
42b4cdd4
[
json
.
exception
.
parse_error
.
107
]
parse
error
at
1
:
JSON
pointer
must
be
empty
or
begin
with
'/'
-
was
:
'foo'
[
json
.
exception
.
parse_error
.
108
]
parse
error
:
escape
character
'~'
must
be
followed
with
'0'
or
'1'
[
json
.
exception
.
parse_error
.
108
]
parse
error
:
escape
character
'~'
must
be
followed
with
'0'
or
'1'
doc/examples/json_pointer__to_string.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/json_pointer__to_string.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/O4FbKx0TbZioFhfU"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/t6BQ8xMgkSUIcy1m"><b>online</b></a>
\ No newline at end of file
doc/examples/max_size.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/max_size.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/NBFk3TxTo32pKt36"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/9j9TwfNlZ88Hvwdi"><b>online</b></a>
\ No newline at end of file
doc/examples/meta.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/meta.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/3hERJociqLo3vdod"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/GTMgDs6Q8uLToRvb"><b>online</b></a>
\ No newline at end of file
doc/examples/meta.output
View file @
4b316ec5
...
...
@@ -2,7 +2,7 @@
"compiler": {
"c++": "201103",
"family": "clang",
"version": "8.
0.0 (clang-800.0.42.1
)"
"version": "8.
1.0 (clang-802.0.42
)"
},
"copyright": "(C) 2013-2017 Niels Lohmann",
"name": "JSON for Modern C++",
...
...
doc/examples/object.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/object.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Ub9U5AMbng3oZiao"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/UeOjT4BeGKdE345o"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__ValueType.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
#include <unordered_map>
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__ValueType.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/drFSKFXJd8IMzMK3"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/3bM7J4Qlj1Cl9EUK"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__equal.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__equal.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/sBTv52u9kI2gjeFJ"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/D7ff222CtzQaAXUK"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__equal.output
View file @
4b316ec5
[1,2,3] == [1,2,4] false
{"A":"a","B":"b"} == {"A":"a","B":"b"} true
17 == 17 true
17 == 17
.0
true
"foo" == "bar" false
doc/examples/operator__equal.test
deleted
100644 → 0
View file @
42b4cdd4
[
1
,
2
,
3
]
==
[
1
,
2
,
4
]
false
{
"A"
:
"a"
,
"B"
:
"b"
}
==
{
"A"
:
"a"
,
"B"
:
"b"
}
true
17
==
17
true
"foo"
==
"bar"
false
doc/examples/operator__equal__nullptr_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__equal__nullptr_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/GGWi3cRmA5A3n1N2"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/2PPEeLTQTrbE8cVN"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__greater.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__greater.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/xJlXYtWnxO1NUh7x"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/whYWnKZxQV8vyrUV"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__greaterequal.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__greaterequal.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/92RTw1dWSVue58j6"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/vIBUY6LRmKBQOgiR"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__less.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__less.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/JrAvlrYH03a2yfRX"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/ZvESrmjGKoagilJr"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__lessequal.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__lessequal.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/m4lNMI48FqF96QWd"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/igiFsYkK3wJxbUBe"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__notequal.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__notequal.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/m4adEpqac1fmOwNn"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/fYRwW2ctRMeM0Lof"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__notequal.output
View file @
4b316ec5
[1,2,3] == [1,2,4] true
{"A":"a","B":"b"} == {"A":"a","B":"b"} false
17 == 17 false
17 == 17
.0
false
"foo" == "bar" true
doc/examples/operator__notequal.test
deleted
100644 → 0
View file @
42b4cdd4
[
1
,
2
,
3
]
==
[
1
,
2
,
4
]
true
{
"A"
:
"a"
,
"B"
:
"b"
}
==
{
"A"
:
"a"
,
"B"
:
"b"
}
false
17
==
17
false
"foo"
==
"bar"
true
doc/examples/operator__notequal__nullptr_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__notequal__nullptr_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Lo7eftLny4Io5rgV"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/ejLtGKtacU0xiZV4"><b>online</b></a>
\ No newline at end of file
doc/examples/operator__value_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator__value_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/n1XysfgD6muGNQdE"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/hVycygNLPkyFqvN5"><b>online</b></a>
\ No newline at end of file
doc/examples/operator_deserialize.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator_deserialize.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/yAAGR07u3IQbIgUa"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/yeEdM1SY7CloqFt3"><b>online</b></a>
\ No newline at end of file
doc/examples/operator_serialize.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operator_serialize.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/NOtGXsCLXYHRG6ML"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/N3DbIOGGiGvGfSQ3"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorarray__key_type.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorarray__key_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ujLOsxCRQE3T8cYO"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/4y25Szh3rTn8pQJg"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorarray__key_type_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorarray__key_type_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/x6rzLLCk96NM36Tl"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/KYhKymZiVPxCBzVc"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorarray__size_type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorarray__size_type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/nRWrbGoBCORCHJI5"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/L1c3a41KITuzSwVS"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorarray__size_type_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorarray__size_type_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/4g1Gn5htCIExLBgW"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/O42CoAYuvKv9qsjI"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorjson_pointer.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorjson_pointer.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/AYgVTzCodPApT4hT"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/5BiKWmmo8E6cZ5ya"><b>online</b></a>
\ No newline at end of file
doc/examples/operatorjson_pointer_const.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/operatorjson_pointer_const.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/IKpbJkMdcocVdlRd"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/t2CPGGr35iE5Ccsd"><b>online</b></a>
\ No newline at end of file
doc/examples/parse__array__parser_callback_t.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/parse__array__parser_callback_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/CwZnqGqte14SYJ5s"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/chPjGeanDIb5ce5Y"><b>online</b></a>
\ No newline at end of file
doc/examples/parse__contiguouscontainer__parser_callback_t.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/parse__contiguouscontainer__parser_callback_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/F8VaVFyys87qQRt5"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/6N1uGjyG56Cgp856"><b>online</b></a>
\ No newline at end of file
doc/examples/parse__istream__parser_callback_t.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/parse__istream__parser_callback_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ir2u6Qbw18O89IWk"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/hRc62HHoix373ban"><b>online</b></a>
\ No newline at end of file
doc/examples/parse__iteratortype__parser_callback_t.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/parse__iteratortype__parser_callback_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ojh4Eeol4G9RgeRV"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Tt8SS2LJXvi0fuUc"><b>online</b></a>
\ No newline at end of file
doc/examples/parse__string__parser_callback_t.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/parse__string__parser_callback_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/n888UNQlMFduURhE"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Wvsf6dhxhscpNbx8"><b>online</b></a>
\ No newline at end of file
doc/examples/patch.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/patch.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/lbczW3AzcUbH1Nbo"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/UoObrzN9bFBGX8ph"><b>online</b></a>
\ No newline at end of file
doc/examples/push_back.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/push_back.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/zz3xkIXJYVhmYAla"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/Y6RwbyukIqP7axhL"><b>online</b></a>
\ No newline at end of file
doc/examples/push_back__initializer_list.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/push_back__initializer_list.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/wZF4dRHjfCyjb3rx"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/EGWCBZOQQ4WbZl6V"><b>online</b></a>
\ No newline at end of file
doc/examples/push_back__object_t__value.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/push_back__object_t__value.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/lmXOd27kgJ2wQGMZ"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/OJH4Aq6qDiGRqXNo"><b>online</b></a>
\ No newline at end of file
doc/examples/rbegin.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/rbegin.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/KiWAz9ZSK8L3k2kg"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/F9EE9JBnMu2KgCC3"><b>online</b></a>
\ No newline at end of file
doc/examples/rend.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/rend.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/2QoIzXRq9ODTMxRf"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/uv1nLqTKpZOwvofB"><b>online</b></a>
\ No newline at end of file
doc/examples/size.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/size.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ykuhQopCVvOXcvs9"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/uBVNNjgvYuX7rcIO"><b>online</b></a>
\ No newline at end of file
doc/examples/swap__array_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/swap__array_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/Hb0oakHEKJ2cuMTE"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/2aZmrP2xuWIiZOfd"><b>online</b></a>
\ No newline at end of file
doc/examples/swap__object_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/swap__object_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/flPVbr8widwRmnad"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/cZGcQj8OrkPrXX9d"><b>online</b></a>
\ No newline at end of file
doc/examples/swap__reference.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/swap__reference.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/gYuvmciucjS8NYY0"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/BYPsq3iXyU04hqpi"><b>online</b></a>
\ No newline at end of file
doc/examples/swap__string_t.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/swap__string_t.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/747DNDuWilHBrac3"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/jtBO4VQr09xU8hfX"><b>online</b></a>
\ No newline at end of file
doc/examples/to_cbor.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/to_cbor.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/UaDbrgZ8OPWaShY8"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/tMjlClOSnAhY0BDg"><b>online</b></a>
\ No newline at end of file
doc/examples/to_msgpack.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/to_msgpack.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/jvaU8GEfAusb5dKf"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/CeF2b7iKuvSnNZaV"><b>online</b></a>
\ No newline at end of file
doc/examples/type.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/type.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/ZqSWHApgHNYddvEU"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/om8MTJzY1FlDzxxS"><b>online</b></a>
\ No newline at end of file
doc/examples/type_name.cpp
View file @
4b316ec5
#include
<json.hpp>
#include
"json.hpp"
using
json
=
nlohmann
::
json
;
...
...
doc/examples/type_name.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/V6imubWo6Lkp8gk1"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/t8yj12vJog4NagqL"><b>online</b></a>
\ No newline at end of file
doc/examples/unflatten.cpp
View file @
4b316ec5
#include <json.hpp>
#include "json.hpp"
#include <iomanip> // for std::setw
using
json
=
nlohmann
::
json
;
...
...
doc/examples/unflatten.link
View file @
4b316ec5
<a target="_blank" href="http://melpon.org/wandbox/permlink/PFBoQVT7RG0e0Wua"><b>online</b></a>
\ No newline at end of file
<a target="_blank" href="https://wandbox.org/permlink/aOxMXevnLZteNqkg"><b>online</b></a>
\ No newline at end of file
src/json.hpp
View file @
4b316ec5
...
...
@@ -5981,6 +5981,52 @@ class basic_json
return
result
;
}
/*!
@brief inserts elements
Inserts elements from range `[first, last)`.
@param[in] first begin of the range of elements to insert
@param[in] last end of the range of elements to insert
@throw type_error.309 if called on JSON values other than objects; example:
`"cannot use insert() with string"`
@throw invalid_iterator.202 if iterator @a first or @a last does does not
point to an object; example: `"iterators first and last must point to
objects"`
@throw invalid_iterator.210 if @a first and @a last do not belong to the
same JSON value; example: `"iterators do not fit"`
@complexity Logarithmic: `O(N*log(size() + N))`, where `N` is the number
of elements to insert.
@liveexample{The example shows how `insert()` is used.,insert__range_object}
@since version 3.0.0
*/
void
insert
(
const_iterator
first
,
const_iterator
last
)
{
// insert only works for objects
if
(
not
is_object
())
{
JSON_THROW
(
type_error
::
create
(
309
,
"cannot use insert() with "
+
type_name
()));
}
// check if range iterators belong to the same JSON object
if
(
first
.
m_object
!=
last
.
m_object
)
{
JSON_THROW
(
invalid_iterator
::
create
(
210
,
"iterators do not fit"
));
}
// passed iterators must belong to objects
if
(
not
first
.
m_object
->
is_object
()
or
not
first
.
m_object
->
is_object
())
{
JSON_THROW
(
invalid_iterator
::
create
(
202
,
"iterators first and last must point to objects"
));
}
m_value
.
object
->
insert
(
first
.
m_it
.
object_iterator
,
last
.
m_it
.
object_iterator
);
}
/*!
@brief exchanges the values
...
...
src/json.hpp.re2c
View file @
4b316ec5
...
...
@@ -5981,6 +5981,52 @@ class basic_json
return result;
}
/*!
@brief inserts elements
Inserts elements from range `[first, last)`.
@param[in] first begin of the range of elements to insert
@param[in] last end of the range of elements to insert
@throw type_error.309 if called on JSON values other than objects; example:
`"cannot use insert() with string"`
@throw invalid_iterator.202 if iterator @a first or @a last does does not
point to an object; example: `"iterators first and last must point to
objects"`
@throw invalid_iterator.210 if @a first and @a last do not belong to the
same JSON value; example: `"iterators do not fit"`
@complexity Logarithmic: `O(N*log(size() + N))`, where `N` is the number
of elements to insert.
@liveexample{The example shows how `insert()` is used.,insert__range_object}
@since version 3.0.0
*/
void insert(const_iterator first, const_iterator last)
{
// insert only works for objects
if (not is_object())
{
JSON_THROW(type_error::create(309, "cannot use insert() with " + type_name()));
}
// check if range iterators belong to the same JSON object
if (first.m_object != last.m_object)
{
JSON_THROW(invalid_iterator::create(210, "iterators do not fit"));
}
// passed iterators must belong to objects
if (not first.m_object->is_object() or not first.m_object->is_object())
{
JSON_THROW(invalid_iterator::create(202, "iterators first and last must point to objects"));
}
m_value.object->insert(first.m_it.object_iterator, last.m_it.object_iterator);
}
/*!
@brief exchanges the values
...
...
test/src/unit-modifiers.cpp
View file @
4b316ec5
...
...
@@ -594,7 +594,7 @@ TEST_CASE("modifiers")
}
}
SECTION
(
"range"
)
SECTION
(
"range
for array
"
)
{
json
j_other_array
=
{
"first"
,
"second"
};
...
...
@@ -631,6 +631,40 @@ TEST_CASE("modifiers")
}
}
SECTION
(
"range for object"
)
{
json
j_object1
=
{{
"one"
,
"eins"
},
{
"two"
,
"zwei"
}};
json
j_object2
=
{{
"eleven"
,
"elf"
},
{
"seventeen"
,
"siebzehn"
}};
SECTION
(
"proper usage"
)
{
j_object1
.
insert
(
j_object2
.
begin
(),
j_object2
.
end
());
CHECK
(
j_object1
.
size
()
==
4
);
}
SECTION
(
"empty range"
)
{
j_object1
.
insert
(
j_object2
.
begin
(),
j_object2
.
begin
());
CHECK
(
j_object1
.
size
()
==
2
);
}
SECTION
(
"invalid iterators"
)
{
json
j_other_array2
=
{
"first"
,
"second"
};
CHECK_THROWS_AS
(
j_array
.
insert
(
j_object2
.
begin
(),
j_object2
.
end
()),
json
::
type_error
);
CHECK_THROWS_AS
(
j_object1
.
insert
(
j_object1
.
begin
(),
j_object2
.
end
()),
json
::
invalid_iterator
);
CHECK_THROWS_AS
(
j_object1
.
insert
(
j_array
.
begin
(),
j_array
.
end
()),
json
::
invalid_iterator
);
CHECK_THROWS_WITH
(
j_array
.
insert
(
j_object2
.
begin
(),
j_object2
.
end
()),
"[json.exception.type_error.309] cannot use insert() with array"
);
CHECK_THROWS_WITH
(
j_object1
.
insert
(
j_object1
.
begin
(),
j_object2
.
end
()),
"[json.exception.invalid_iterator.210] iterators do not fit"
);
CHECK_THROWS_WITH
(
j_object1
.
insert
(
j_array
.
begin
(),
j_array
.
end
()),
"[json.exception.invalid_iterator.202] iterators first and last must point to objects"
);
}
}
SECTION
(
"initializer list at position"
)
{
SECTION
(
"insert before begin()"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment