Input Archive
Deserialization of JSON input directly into C data structures is done with the help of Boost.Serialization. The input archive transforms the entire JSON input into C data structures all at once.
The full parser transforms the entire input into a data structure. This is done via an input archive (called iarchive.) You can either use a generic tree data structure, such as dynamic-cpp, as the Document Object Model, or you can parse the input directly into your own data structures or the standard containers in C++.
Simple types
#include <trial/protocol/buffer/string.hpp>
#include <trial/protocol/json/serialization.hpp>
std::string input = "true";
json::iarchive archive(input);
bool result;
archive >> result; // Read the boolean value
assert(result == true);