Benoit Blanchon
4871380060
Rename MemoryPool to ResourceManager
2023-06-18 10:14:39 +02:00
Benoit Blanchon
da45c4bc4f
Fix memory leak in JsonDeserializer when object key is repeated
2023-05-25 09:21:54 +02:00
Benoit Blanchon
37357086e2
Remove the zero-copy mode
...
After removing the string size from `VariantContent`, `deserializeJson()` and `deserializeMsgPack()` could not support NUL in strings in the zero-copy mode anymore.
Instead of adding a complicated warning in the documentation, I thought it was better to remove the zero-copy mode entirely.
The zero-copy mode has always been a source of bugs because many users used it without realizing it.
Also, the memory savings are smaller now that we deduplicate strings, so this feature should not be missed much.
2023-05-10 09:55:21 +02:00
Benoit Blanchon
d8f3058efa
Store the strings in the heap
2023-04-17 10:42:08 +02:00
Benoit Blanchon
e9850152a7
Tests: replace constants with sizeofString(n)
2023-04-07 14:50:54 +02:00
Benoit Blanchon
035c913c72
Remove ARDUINOJSON_ENABLE_STRING_DEDUPLICATION
2023-03-29 19:28:44 +02:00
Benoit Blanchon
3f43c2b816
Remove JSON_ARRAY_SIZE(), JSON_OBJECT_SIZE(), and JSON_STRING_SIZE()
2023-03-29 19:18:06 +02:00
Benoit Blanchon
0328f66340
Fix compatibility with GCC 5.2
2023-03-28 17:24:45 +02:00
Benoit Blanchon
540901e219
Merge DynamicJsonDocument with JsonDocument
2023-03-20 14:49:51 +01:00
Benoit Blanchon
17a482a9b1
Remove StaticJsonDocument
2023-03-20 10:40:35 +01:00
Benoit Blanchon
daa87e12dc
Update copyright notice
2023-02-16 11:45:01 +01:00
Benoit Blanchon
1b66a217bf
Replace ARDUINOJSON_NAMESPACE with an inline namespace ( #1820 )
2023-02-14 10:04:48 +01:00
Benoit Blanchon
62dea9d364
Reformat CMake files
2023-02-10 17:02:51 +01:00
Benoit Blanchon
007b4f3362
Update Catch library to 2.13.10 ( #1820 )
2023-02-10 17:02:51 +01:00
Johan Vromans
3345255f16
Fix comma tests.
2023-01-13 08:21:54 +01:00
Benoit Blanchon
1d21027e2a
Fix lax parsing of true, false, and null ( fixes #1781 )
2022-08-06 09:15:07 +02:00
Benoit Blanchon
421ecec0dd
Tests: trim trailing white spaces
2022-02-25 10:28:42 +01:00
Benoit Blanchon
89ed54362b
Fix -Wsign-conversion on GCC 8 ( fixes #1715 )
2022-02-25 10:28:42 +01:00
Benoit Blanchon
21b2c76524
Fix filter not working in zero-copy mode ( fixes #1697 )
2022-01-13 20:25:49 +01:00
Benoit Blanchon
af18994deb
Update copyright notice
2022-01-01 10:01:05 +01:00
Benoit Blanchon
be70f6ddd7
Support NUL inside string values (issue #1646 )
2021-12-07 16:08:44 +01:00
Benoit Blanchon
43b2e2e774
Append terminator in saveStringFromFreeZone()
2021-11-24 19:06:49 +01:00
Benoit Blanchon
5ed5f3687b
Improve test coverage
2021-10-24 09:58:39 +02:00
Benoit Blanchon
943a902a0b
Remove DeserializationError == bool and DeserializationError != bool
2021-10-24 09:58:39 +02:00
Benoit Blanchon
956e4a7cbb
Fixed deserialization of \u0000 (issue #1646 )
2021-08-31 14:23:58 +02:00
Benoit Blanchon
2c3ae1c181
Filter: exact match takes precedence over wildcard ( fixes #1628 )
2021-08-13 10:35:15 +02:00
Benoit Blanchon
14639f129e
CMake: added empty line at end of each file
2021-06-26 11:29:15 +02:00
Benoit Blanchon
7be0c2c650
CMake: added labels to tests
2021-04-25 11:38:19 +02:00
Benoit Blanchon
d5d2209d09
Added "https://" prefix to all URLs so they are clickable in VS Code
2021-03-29 19:35:25 +02:00
Benoit Blanchon
e4ce75e20c
Simplified JsonVariant::as<T>() to always return T
2021-03-08 19:33:52 +01:00
Benoit Blanchon
1038fc35df
Removed DeserializationError::NotSupported
2021-02-18 19:41:15 +01:00
Benoit Blanchon
97b7161d78
Update copyright notice for 2021
2021-01-25 09:14:15 +01:00
Benoit Blanchon
712005219c
Added filtering for MessagePack ( closes #1298 , closes #1394 )
2020-10-13 09:40:39 +02:00
Benoit Blanchon
8385d5fa3a
Added wildcard key (*) for filters ( closes #1309 )
2020-09-28 21:11:38 +02:00
Benoit Blanchon
c907ca6e5d
Added DeserializationError::EmptyInput
2020-09-13 10:27:29 +02:00
Benoit Blanchon
35a39b8d8f
Fixed deserializeJson() that stopped reading after {} ( fixes #1335 )
2020-08-04 09:52:42 +02:00
Benoit Blanchon
4df29fbac1
Fixed "linked" strings incorrectly marked as "owned" ( fixes #1318 )
2020-07-24 22:25:56 +02:00
Benoit Blanchon
764ff2cd53
Added string deduplication ( closes #1303 )
2020-07-21 20:15:31 +02:00
Benoit Blanchon
1600d39693
Refactored StringBuilder into StringStorage
2020-07-11 17:51:45 +02:00
Benoit Blanchon
04c59985a1
Inverted dependency between MemoryPool and string adapters.
...
Inserted a null after each raw string in the pool.
2020-07-08 09:38:27 +02:00
Benoit Blanchon
95f05dad66
Added JsonVariant as an input type for deserializeXxx()
2020-05-05 13:16:32 +02:00
Benoit Blanchon
dcf7eeef28
CMake: used link_libraries() instead of target_link_libraries()
2020-05-03 10:25:38 +02:00
Benoit Blanchon
1791dccbf2
Added CMake "install" target ( closes #1209 )
2020-04-07 21:43:10 +02:00
Benoit Blanchon
1902c0ec93
Improved coverage of JsonDeserializer
2020-02-19 10:31:56 +01:00
Benoit Blanchon
6e52f242b2
Extracted the class Latch
...
also fixed a buffer overrun and reduced the code size
2020-02-13 14:53:54 +01:00
Benoit Blanchon
66b12da4e7
Added DeserializationOption::Filter ( closes #959 )
2020-02-12 17:22:42 +01:00
Benoit Blanchon
09d4b2cd38
Fixed regression in UTF16 decoding ( fixes #1173 )
2020-01-27 12:10:10 +01:00
Benoit Blanchon
04fe7e1a27
Added ARDUINOJSON_ENABLE_COMMENTS to enable support for comments
2020-01-13 18:16:02 +01:00
Benoit Blanchon
f9cfea244a
Updated copyright notice
2020-01-09 15:48:38 +01:00
Benoit Blanchon
5ec062cc71
Reduced Unicode conversion code size (-122 bytes on AVR)
2020-01-09 15:39:45 +01:00