Availability:
:- use_module(library(http/json)).
[det]json_read_dict(+Stream,
-Dict)
- String values are mapped to Prolog strings
- JSON
true,falseandnullare represented using these Prolog atoms. - JSON objects are mapped to dicts.
- By default, a
typefield in an object assigns a tag for the dict.
The predicate json_read_dict/3
processes the same options as
json_read/3, but with different
defaults. In addition, it processes the tag option. See json_read/3
for details about the shared options.
- tag(+Name)
- When converting to/from a dict, map the indicated JSON attribute to the dict tag. No mapping is performed if Name is the empty atom ('', default). See json_read_dict/2 and json_write_dict/2.
- null(+NullTerm)
- Default the atom
null. - true(+TrueTerm)
- Default the atom
true. - false(+FalseTerm)
- Default the atom
false - value_string_as(+Type)
- Type defaults to
string, producing a packed string object.