Skip to main content

json

include "json";

Read JSON documents and look up their values by path (JSON Pointer, such as "/player/name").

Types​

json​

Native object

kind infallible​

infallible fn kind(string pointer) -> int

has infallible​

infallible fn has(string pointer) -> bool

count infallible​

infallible fn count(string pointer) -> int

key​

fn key(string pointer, int index) -> string

string​

fn string(string pointer) -> string

bool_value​

fn bool_value(string pointer) -> bool

int_value​

fn int_value(string pointer) -> int

float_value​

fn float_value(string pointer) -> float

close infallible​

infallible fn close()

Functions​

json_parse​

fn json_parse(string text) -> json

Parses text into a JSON document. Close it when done.