Module Reader_monad.Make
Parameters
Signature
module IO : Jsonxt__.Io.IO
type json
= Parser.Compliance.json
val read_json : ?stream:bool -> reader:(Stdlib.Bytes.t -> int -> int IO.t) -> unit -> (json, string) Stdlib.result IO.t
read_json
takes areader
function and returns ajson
value or an error if the string has syntax, grammar or compliance errors. Thereader buf len
parameter reads at mostlen
bytes intobuf
and returns the number of bytes read. Zero indicates end of file. The optionalstream
parameter specifies if multiplejson
objects are to be read, defaulting tofalse