View Source simdjson (simdjsone v0.1.2)

Fast decoding of JSON using simdjson C++ library.

By default JSON decoder uses the atom null to represent JSON nulls. To modify this behavior, set the following configuration option to another atom value (e.g. nil for Elixir):
   {simdjsone, [{null, nil}]}.
See also https://github.com/simdjson/simdjson

Link to this section Summary

Functions

Decode a JSON string or binary to a term representation of JSON.
Find a given Path (which must start with a slash) in the JSON resource. The resource reference must have been previously created by calling parse/1,2.
Minify a JSON string or binary.
Parse a JSON string or binary and save it in a resource for later access by get/2. Returns a resource reference owned by the calling pid.

Link to this section Functions

-spec decode(binary() | list() | reference()) -> term().
Decode a JSON string or binary to a term representation of JSON.
-spec get(reference(), binary()) -> term().
Find a given Path (which must start with a slash) in the JSON resource. The resource reference must have been previously created by calling parse/1,2.
-spec minify(binary() | list()) -> {ok, binary()} | {error, binary()}.
Minify a JSON string or binary.
-spec parse(binary()) -> reference().
Parse a JSON string or binary and save it in a resource for later access by get/2. Returns a resource reference owned by the calling pid.