null_category
Conversion category for null types.
Synopsis
Defined in header <boost/json/conversion.hpp>.
struct null_category;
Description
Null types are represented in JSON as the null
literal.
By default only the type std::nullptr_t
is considered a null type.
Users can specialize conversion_category_for
for their own types if they want them to be treated as nulls. For example:
namespace boost {
namespace json {
template <>
struct conversion_category_for<your::null>
{
using type = null_category;
};
} // namespace boost
} // namespace json
Matching Types
Convenience header <boost/json.hpp>.