diff --git a/api/adl_serializer/from_json/index.html b/api/adl_serializer/from_json/index.html index cb3f638d1..1885e77f1 100644 --- a/api/adl_serializer/from_json/index.html +++ b/api/adl_serializer/from_json/index.html @@ -9,7 +9,7 @@ static auto from_json(BasicJsonType && j) noexcept( noexcept(::nlohmann::from_json(std::forward<BasicJsonType>(j), detail::identity_tag<TargetType> {}))) -> decltype(::nlohmann::from_json(std::forward<BasicJsonType>(j), detail::identity_tag<TargetType> {})) -
This function is usually called by the get() function of the basic_json class (either explicitly or via the conversion operators).
j (in)val (out)Copy of the JSON value, converted to ValueType
The example below shows how a from_json function can be implemented for a user-defined type. This function is called by the adl_serializer when get<ns::person>() is called.
#include <iostream>
+This function is usually called by the get() function of the basic_json class (either explicitly or via the conversion operators).
j (in)val (out)val.j converted to TargetTypeThe example below shows how a from_json function can be implemented for a user-defined type. This function is called by the adl_serializer when get<ns::person>() is called.
#include <iostream>
#include <nlohmann/json.hpp>
using json = nlohmann::json;
@@ -101,4 +101,4 @@
std::cout << p.name << " (" << p.age << ") lives in " << p.address << std::endl;
}
Output:
Ned Flanders (60) lives in 744 Evergreen Terrace
-