The json.JSONWriter class
The json.JSONWriter
class provides an interface compatible with JSON
streaming that writes data in a JSON format to an output source.
The
json.JSONWriter
class is provided in the json
C-Extension library. To use the
json.JSONWriter
class, you must import the json
package in your
program:IMPORT json
The json.JSONWriter
class implements a method to create a
json.JSONWriter
object.
The purpose of the json.JSONWriter
class is to process JSON text to interface
with software based on the JSON format by streaming it in a sequence of tokens, one token at a time,
instead of loading it into memory. The stream includes both literal values (strings, numbers,
booleans, and null) as well as the begin and end delimiters of JSON's two structured types (objects
and arrays).