|
static char * | json_strdup (const char *str) |
|
static void | sb_init (SB *sb) |
|
static void | sb_grow (SB *sb, int need) |
|
static void | sb_put (SB *sb, const char *bytes, int count) |
|
static void | sb_puts (SB *sb, const char *str) |
|
static char * | sb_finish (SB *sb) |
|
static void | sb_free (SB *sb) |
|
static int | utf8_validate_cz (const char *s) |
|
static bool | utf8_validate (const char *s) |
|
static int | utf8_read_char (const char *s, uchar_t *out) |
|
static int | utf8_write_char (uchar_t unicode, char *out) |
|
static bool | from_surrogate_pair (uint16_t uc, uint16_t lc, uchar_t *unicode) |
|
static void | to_surrogate_pair (uchar_t unicode, uint16_t *uc, uint16_t *lc) |
|
static bool | parse_value (const char **sp, JsonNode **out) |
|
static bool | parse_string (const char **sp, char **out) |
|
static bool | parse_number (const char **sp, double *out) |
|
static bool | parse_array (const char **sp, JsonNode **out) |
|
static bool | parse_object (const char **sp, JsonNode **out) |
|
static bool | parse_hex16 (const char **sp, uint16_t *out) |
|
static bool | expect_literal (const char **sp, const char *str) |
|
static void | skip_space (const char **sp) |
|
static void | emit_value (SB *out, const JsonNode *node) |
|
static void | emit_value_indented (SB *out, const JsonNode *node, const char *space, int indent_level) |
|
static void | emit_string (SB *out, const char *str) |
|
static void | emit_number (SB *out, double num) |
|
static void | emit_array (SB *out, const JsonNode *array) |
|
static void | emit_array_indented (SB *out, const JsonNode *array, const char *space, int indent_level) |
|
static void | emit_object (SB *out, const JsonNode *object) |
|
static void | emit_object_indented (SB *out, const JsonNode *object, const char *space, int indent_level) |
|
static int | write_hex16 (char *out, uint16_t val) |
|
static JsonNode * | mknode (JsonTag tag) |
|
static void | append_node (JsonNode *parent, JsonNode *child) |
|
static void | prepend_node (JsonNode *parent, JsonNode *child) |
|
static void | append_member (JsonNode *object, char *key, JsonNode *value) |
|
static bool | tag_is_valid (unsigned int tag) |
|
static bool | number_is_valid (const char *num) |
|
JsonNode * | json_decode (const char *json) |
|
char * | json_encode (const JsonNode *node) |
|
char * | json_encode_string (const char *str) |
|
char * | json_stringify (const JsonNode *node, const char *space) |
|
void | json_delete (JsonNode *node) |
|
bool | json_validate (const char *json) |
|
JsonNode * | json_find_element (JsonNode *array, int index) |
|
JsonNode * | json_find_member (JsonNode *object, const char *name) |
|
JsonNode * | json_first_child (const JsonNode *node) |
|
JsonNode * | json_mknull (void) |
|
JsonNode * | json_mkbool (bool b) |
|
static JsonNode * | mkstring (char *s) |
|
JsonNode * | json_mkstring (const char *s) |
|
JsonNode * | json_mknumber (double n) |
|
JsonNode * | json_mkarray (void) |
|
JsonNode * | json_mkobject (void) |
|
void | json_append_element (JsonNode *array, JsonNode *element) |
|
void | json_prepend_element (JsonNode *array, JsonNode *element) |
|
void | json_append_member (JsonNode *object, const char *key, JsonNode *value) |
|
void | json_prepend_member (JsonNode *object, const char *key, JsonNode *value) |
|
void | json_remove_from_parent (JsonNode *node) |
|
bool | json_check (const JsonNode *node, char errmsg[256]) |
|