Nlohmann-json

Latest version: v3.11.3

Safety actively analyzes 688705 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 8 of 8

1.0.0

- Release date: 2015-12-28
- SHA-256: 767dc2fab1819d7b9e19b6e456d61e38d21ef7182606ecf01516e3f5230446de

Summary

This is the first official release. Compared to the [prerelease version 1.0.0-rc1](https://github.com/nlohmann/json/releases/tag/v1.0.0-rc1), only a few minor improvements have been made:

Changes
- _Changed_: A **UTF-8 byte order mark** is silently ignored.
- _Changed_: `sprintf` is no longer used.
- _Changed_: `iterator_wrapper` also works for const objects; note: the name may change!
- _Changed_: **Error messages** during deserialization have been improved.
- _Added_: The `parse` function now also works with type `std::istream&&`.
- _Added_: Function `value(key, default_value)` returns either a copy of an object's element at the specified key or a given default value if no element with the key exists.
- _Added_: Public functions are tagged with the version they were introduced. This shall allow for better **versioning** in the future.
- _Added_: All public functions and types are **documented** (see http://nlohmann.github.io/json/) including executable examples.
- _Added_: Allocation of all types (in particular arrays, strings, and objects) is now exception-safe.
- _Added_: They descriptions of thrown exceptions have been overworked and are part of the tests suite and documentation.

1.0.0rc1

- Release date: 2015-07-26
- SHA-256: b87b2565b9786abb938c1f0ac5793fa99220509084220edc45f59aab2dec57e2

Summary

The 1.0.0 release should be the first "official" release after the initial announcement of the class in January 2015 via reddit ("0.1.0") and a heavily overworked second version ("0.2.0") in February.

Changes
- _Changed:_ In the generic class `basic_json`, all JSON value types (array, object, string, bool, integer number, and floating-point) are now **templated**. That is, you can choose whether you like a `std::list` for your arrays or an `std::unordered_map` for your objects. The specialization `json` sets some reasonable defaults.
- _Changed:_ The library now consists of a **single header**, called `json.hpp`. Consequently, build systems such as Automake or CMake are not any longer required.
- _Changed:_ The **deserialization** is now supported by a lexer generated with [re2c](http://re2c.org) from file [`src/json.hpp.re2c`](https://github.com/nlohmann/json/blob/master/src/json.hpp.re2c). As a result, we strictly follow the JSON specification. Note neither the tool re2c nor its input are required to use the class.
- _Added:_ The library now satisfies the [**ReversibleContainer**](http://en.cppreference.com/w/cpp/concept/ReversibleContainer) requirement. It hence provides four different iterators (`iterator`, `const_iterator`, `reverse_iterator`, and `const_reverse_iterator`), comparison functions, `swap()`, `size()`, `max_size()`, and `empty()` member functions.
- _Added_: The class uses **user-defined allocators** which default to `std::allocator`, but can be templated via parameter `Allocator`.
- _Added:_ To simplify pretty-printing, the `std::setw` **stream manipulator** has been overloaded to set the desired indentation. Pretty-printing a JSON object `j` is as simple as `std::cout << std::setw(4) << j << '\n'`.
- _Changed_: The type `json::value_t::number` is now called `json::value_t::number_integer` to be more symmetric compared to `json::value_t::number_float`.
- _Added_: The documentation is generated with Doxygen and hosted at [nlohmann.github.io/json](http://nlohmann.github.io/json/). Every public member function is thoroughly described including an example which also can be [tried online](http://melpon.org/wandbox/permlink/GnGKwji06WeVonlI).
- _Added_: The class is heavily unit-tested (3341774 assertions) and has a [line coverage of 100%](https://coveralls.io/github/nlohmann/json). With every commit, the code is compiled with g++ 4.9, g++ 5.0, Clang 3.6 (thanks to [Travis CI](https://travis-ci.org/nlohmann/json)), and Microsoft Visual Studio 14 2015 (thanks to [AppVeyor](https://ci.appveyor.com/project/nlohmann/json)).

Page 8 of 8

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.