[209] | 1 | ArduinoJson: change log
|
---|
| 2 | =======================
|
---|
| 3 |
|
---|
| 4 | v5.1.1
|
---|
| 5 | ------
|
---|
| 6 |
|
---|
| 7 | * Removed `String` duplication when one replaces a value in a `JsonObject` (PR #232 by @ulion)
|
---|
| 8 |
|
---|
| 9 | v5.1.0
|
---|
| 10 | ------
|
---|
| 11 |
|
---|
| 12 | * Added support of `long long` (issue #171)
|
---|
| 13 | * Moved all build settings to `ArduinoJson/Configuration.hpp`
|
---|
| 14 |
|
---|
| 15 | **BREAKING CHANGE**:
|
---|
| 16 | If you defined `ARDUINOJSON_ENABLE_STD_STREAM`, you now need to define it to `1`.
|
---|
| 17 |
|
---|
| 18 | v5.0.8
|
---|
| 19 | ------
|
---|
| 20 |
|
---|
| 21 | * Made the library compatible with [PlatformIO](http://platformio.org/) (issue #181)
|
---|
| 22 | * Fixed `JsonVariant::is<bool>()` that was incorrectly returning false (issue #214)
|
---|
| 23 |
|
---|
| 24 | v5.0.7
|
---|
| 25 | ------
|
---|
| 26 |
|
---|
| 27 | * Made library easier to use from a CMake project: simply `add_subdirectory(ArduinoJson/src)`
|
---|
| 28 | * Changed `String` to be a `typedef` of `std::string` (issues #142 and #161)
|
---|
| 29 |
|
---|
| 30 | **BREAKING CHANGES**:
|
---|
| 31 | - `JsonVariant(true).as<String>()` now returns `"true"` instead of `"1"`
|
---|
| 32 | - `JsonVariant(false).as<String>()` now returns `"false"` instead of `"0"`
|
---|
| 33 |
|
---|
| 34 | v5.0.6
|
---|
| 35 | ------
|
---|
| 36 |
|
---|
| 37 | * Added parameter to `DynamicJsonBuffer` constructor to set initial size (issue #152)
|
---|
| 38 | * Fixed warning about library category in Arduino 1.6.6 (issue #147)
|
---|
| 39 | * Examples: Added a loop to wait for serial port to be ready (issue #156)
|
---|
| 40 |
|
---|
| 41 | v5.0.5
|
---|
| 42 | ------
|
---|
| 43 |
|
---|
| 44 | * Added overload `JsonObjectSuscript::set(value, decimals)` (issue #143)
|
---|
| 45 | * Use `float` instead of `double` to reduce the size of `JsonVariant` (issue #134)
|
---|
| 46 |
|
---|
| 47 | v5.0.4
|
---|
| 48 | ------
|
---|
| 49 |
|
---|
| 50 | * Fixed ambiguous overload with `JsonArraySubscript` and `JsonObjectSubscript` (issue #122)
|
---|
| 51 |
|
---|
| 52 | v5.0.3
|
---|
| 53 | ------
|
---|
| 54 |
|
---|
| 55 | * Fixed `printTo(String)` which wrote numbers instead of strings (issue #120)
|
---|
| 56 | * Fixed return type of `JsonArray::is<T>()` and some others (issue #121)
|
---|
| 57 |
|
---|
| 58 | v5.0.2
|
---|
| 59 | ------
|
---|
| 60 |
|
---|
| 61 | * Fixed segmentation fault in `parseObject(String)` and `parseArray(String)`, when the
|
---|
| 62 | `StaticJsonBuffer` is too small to hold a copy of the string
|
---|
| 63 | * Fixed Clang warning "register specifier is deprecated" (issue #102)
|
---|
| 64 | * Fixed GCC warning "declaration shadows a member" (issue #103)
|
---|
| 65 | * Fixed memory alignment, which made ESP8266 crash (issue #104)
|
---|
| 66 | * Fixed compilation on Visual Studio 2010 and 2012 (issue #107)
|
---|
| 67 |
|
---|
| 68 | v5.0.1
|
---|
| 69 | ------
|
---|
| 70 |
|
---|
| 71 | * Fixed compilation with Arduino 1.0.6 (issue #99)
|
---|
| 72 |
|
---|
| 73 | v5.0.0
|
---|
| 74 | ------
|
---|
| 75 |
|
---|
| 76 | * Added support of `String` class (issues #55, #56, #70, #77)
|
---|
| 77 | * Added `JsonBuffer::strdup()` to make a copy of a string (issues #10, #57)
|
---|
| 78 | * Implicitly call `strdup()` for `String` but not for `char*` (issues #84, #87)
|
---|
| 79 | * Added support of non standard JSON input (issue #44)
|
---|
| 80 | * Added support of comments in JSON input (issue #88)
|
---|
| 81 | * Added implicit cast between numerical types (issues #64, #69, #93)
|
---|
| 82 | * Added ability to read number values as string (issue #90)
|
---|
| 83 | * Redesigned `JsonVariant` to leverage converting constructors instead of assignment operators (issue #66)
|
---|
| 84 | * Switched to new the library layout (requires Arduino 1.0.6 or above)
|
---|
| 85 |
|
---|
| 86 | **BREAKING CHANGES**:
|
---|
| 87 | - `JsonObject::add()` was renamed to `set()`
|
---|
| 88 | - `JsonArray::at()` and `JsonObject::at()` were renamed to `get()`
|
---|
| 89 | - Number of digits of floating point value are now set with `double_with_n_digits()`
|
---|
| 90 |
|
---|
| 91 | **Personal note about the `String` class**:
|
---|
| 92 | Support of the `String` class has been added to the library because many people use it in their programs.
|
---|
| 93 | However, you should not see this as an invitation to use the `String` class.
|
---|
| 94 | The `String` class is **bad** because it uses dynamic memory allocation.
|
---|
| 95 | Compared to static allocation, it compiles to a bigger, slower program, and is less predictable.
|
---|
| 96 | You certainly don't want that in an embedded environment!
|
---|
| 97 |
|
---|
| 98 | v4.6
|
---|
| 99 | ----
|
---|
| 100 |
|
---|
| 101 | * Fixed segmentation fault in `DynamicJsonBuffer` when memory allocation fails (issue #92)
|
---|
| 102 |
|
---|
| 103 | v4.5
|
---|
| 104 | ----
|
---|
| 105 |
|
---|
| 106 | * Fixed buffer overflow when input contains a backslash followed by a terminator (issue #81)
|
---|
| 107 |
|
---|
| 108 | **Upgrading is recommended** since previous versions contain a potential security risk.
|
---|
| 109 |
|
---|
| 110 | Special thanks to [Giancarlo Canales Barreto](https://github.com/gcanalesb) for finding this nasty bug.
|
---|
| 111 |
|
---|
| 112 | v4.4
|
---|
| 113 | ----
|
---|
| 114 |
|
---|
| 115 | * Added `JsonArray::measureLength()` and `JsonObject::measureLength()` (issue #75)
|
---|
| 116 |
|
---|
| 117 | v4.3
|
---|
| 118 | ----
|
---|
| 119 |
|
---|
| 120 | * Added `JsonArray::removeAt()` to remove an element of an array (issue #58)
|
---|
| 121 | * Fixed stack-overflow in `DynamicJsonBuffer` when parsing huge JSON files (issue #65)
|
---|
| 122 | * Fixed wrong return value of `parseArray()` and `parseObject()` when allocation fails (issue #68)
|
---|
| 123 |
|
---|
| 124 | v4.2
|
---|
| 125 | ----
|
---|
| 126 |
|
---|
| 127 | * Switched back to old library layout (issues #39, #43 and #45)
|
---|
| 128 | * Removed global new operator overload (issue #40, #45 and #46)
|
---|
| 129 | * Added an example with EthernetServer
|
---|
| 130 |
|
---|
| 131 | v4.1
|
---|
| 132 | ----
|
---|
| 133 |
|
---|
| 134 | * Added DynamicJsonBuffer (issue #19)
|
---|
| 135 |
|
---|
| 136 | v4.0
|
---|
| 137 | ----
|
---|
| 138 |
|
---|
| 139 | * Unified parser and generator API (issue #23)
|
---|
| 140 | * Updated library layout, now requires Arduino 1.0.6 or newer
|
---|
| 141 |
|
---|
| 142 | **BREAKING CHANGE**: API changed significantly, see [Migrating code to the new API](https://github.com/bblanchon/ArduinoJson/wiki/Migrating-code-to-the-new-API).
|
---|
| 143 |
|
---|
| 144 |
|
---|
| 145 | v3.4
|
---|
| 146 | ----
|
---|
| 147 |
|
---|
| 148 | * Fixed escaped char parsing (issue #16)
|
---|
| 149 |
|
---|
| 150 |
|
---|
| 151 | v3.3
|
---|
| 152 | ----
|
---|
| 153 |
|
---|
| 154 | * Added indented output for the JSON generator (issue #11), see example bellow.
|
---|
| 155 | * Added `IndentedPrint`, a decorator for `Print` to allow indented output
|
---|
| 156 |
|
---|
| 157 | Example:
|
---|
| 158 |
|
---|
| 159 | JsonOject<2> json;
|
---|
| 160 | json["key"] = "value";
|
---|
| 161 | json.prettyPrintTo(Serial);
|
---|
| 162 |
|
---|
| 163 | v3.2
|
---|
| 164 | ----
|
---|
| 165 |
|
---|
| 166 | * Fixed a bug when adding nested object in `JsonArray` (bug introduced in v3.1).
|
---|
| 167 |
|
---|
| 168 | v3.1
|
---|
| 169 | ----
|
---|
| 170 |
|
---|
| 171 | * Calling `Generator::JsonObject::add()` twice with the same `key` now replaces the `value`
|
---|
| 172 | * Added `Generator::JsonObject::operator[]`, see bellow the new API
|
---|
| 173 | * Added `Generator::JsonObject::remove()` (issue #9)
|
---|
| 174 |
|
---|
| 175 | Old generator API:
|
---|
| 176 |
|
---|
| 177 | JsonObject<3> root;
|
---|
| 178 | root.add("sensor", "gps");
|
---|
| 179 | root.add("time", 1351824120);
|
---|
| 180 | root.add("data", array);
|
---|
| 181 |
|
---|
| 182 | New generator API:
|
---|
| 183 |
|
---|
| 184 | JsonObject<3> root;
|
---|
| 185 | root["sensor"] = "gps";
|
---|
| 186 | root["time"] = 1351824120;
|
---|
| 187 | root["data"] = array;
|
---|
| 188 |
|
---|
| 189 | v3.0
|
---|
| 190 | ----
|
---|
| 191 |
|
---|
| 192 | * New parser API, see bellow
|
---|
| 193 | * Renamed `JsonHashTable` into `JsonObject`
|
---|
| 194 | * Added iterators for `JsonArray` and `JsonObject` (issue #4)
|
---|
| 195 |
|
---|
| 196 | Old parser API:
|
---|
| 197 |
|
---|
| 198 | JsonHashTable root = parser.parseHashTable(json);
|
---|
| 199 |
|
---|
| 200 | char* sensor = root.getString("sensor");
|
---|
| 201 | long time = root.getLong("time");
|
---|
| 202 | double latitude = root.getArray("data").getDouble(0);
|
---|
| 203 | double longitude = root.getArray("data").getDouble(1);
|
---|
| 204 |
|
---|
| 205 | New parser API:
|
---|
| 206 |
|
---|
| 207 | JsonObject root = parser.parse(json);
|
---|
| 208 |
|
---|
| 209 | char* sensor = root["sensor"];
|
---|
| 210 | long time = root["time"];
|
---|
| 211 | double latitude = root["data"][0];
|
---|
| 212 | double longitude = root["data"][1];
|
---|
| 213 |
|
---|
| 214 | v2.1
|
---|
| 215 | ----
|
---|
| 216 |
|
---|
| 217 | * Fixed case `#include "jsmn.cpp"` which caused an error in Linux (issue #6)
|
---|
| 218 | * Fixed a buffer overrun in JSON Parser (issue #5)
|
---|
| 219 |
|
---|
| 220 | v2.0
|
---|
| 221 | ----
|
---|
| 222 |
|
---|
| 223 | * Added JSON encoding (issue #2)
|
---|
| 224 | * Renamed the library `ArduinoJsonParser` becomes `ArduinoJson`
|
---|
| 225 |
|
---|
| 226 | **Breaking change**: you need to add the following line at the top of your program.
|
---|
| 227 |
|
---|
| 228 | using namespace ArduinoJson::Parser;
|
---|
| 229 |
|
---|
| 230 | v1.2
|
---|
| 231 | ----
|
---|
| 232 |
|
---|
| 233 | * Fixed error in JSON parser example (issue #1)
|
---|
| 234 |
|
---|
| 235 | v1.1
|
---|
| 236 | ----
|
---|
| 237 |
|
---|
| 238 | * Example: changed `char* json` into `char[] json` so that the bytes are not write protected
|
---|
| 239 | * Fixed parsing bug when the JSON contains multi-dimensional arrays
|
---|
| 240 |
|
---|
| 241 | v1.0
|
---|
| 242 | ----
|
---|
| 243 |
|
---|
| 244 | Initial release
|
---|