Enum value_t¶
Defined in File json.hpp
Enum Documentation¶
-
enum class nlohmann::json_abi_v3_11_3::detail::value_t : std::uint8_t¶
the JSON type enumeration
This enumeration collects the different JSON types. It is internally used to distinguish the stored values, and the functions basic_json::is_null(), basic_json::is_object(), basic_json::is_array(), basic_json::is_string(), basic_json::is_boolean(), basic_json::is_number() (with basic_json::is_number_integer(), basic_json::is_number_unsigned(), and basic_json::is_number_float()), basic_json::is_discarded(), basic_json::is_primitive(), and basic_json::is_structured() rely on it.
See also
see basic_json::basic_json(const value_t value_type) — create a JSON value with the default value for a given type
- Since
version 1.0.0
Note
There are three enumeration entries (number_integer, number_unsigned, and number_float), because the library distinguishes these three types for numbers: basic_json::number_unsigned_t is used for unsigned integers, basic_json::number_integer_t is used for signed integers, and basic_json::number_float_t is used for floating-point numbers or to approximate integers which do not fit in the limits of their respective type.
Values:
-
enumerator null¶
null value
-
enumerator object¶
object (unordered set of name/value pairs)
-
enumerator array¶
array (ordered collection of values)
-
enumerator string¶
string value
-
enumerator boolean¶
boolean value
-
enumerator number_integer¶
number value (signed integer)
-
enumerator number_unsigned¶
number value (unsigned integer)
-
enumerator number_float¶
number value (floating-point)
-
enumerator binary¶
binary array (ordered collection of bytes)
-
enumerator discarded¶
discarded by the parser callback function