129Svbart@nginx.com 229Svbart@nginx.com /* 329Svbart@nginx.com * Copyright (C) Igor Sysoev 429Svbart@nginx.com * Copyright (C) Valentin V. Bartenev 529Svbart@nginx.com * Copyright (C) NGINX, Inc. 629Svbart@nginx.com */ 729Svbart@nginx.com 829Svbart@nginx.com #ifndef _NXT_CONF_INCLUDED_ 929Svbart@nginx.com #define _NXT_CONF_INCLUDED_ 1029Svbart@nginx.com 1129Svbart@nginx.com 1229Svbart@nginx.com typedef struct nxt_conf_json_value_s nxt_conf_json_value_t; 1351Svbart@nginx.com typedef struct nxt_conf_json_op_s nxt_conf_json_op_t; 1429Svbart@nginx.com 1529Svbart@nginx.com 1645Svbart@nginx.com typedef struct { 1791Svbart@nginx.com uint32_t level; 1891Svbart@nginx.com uint8_t more_space; /* 1 bit. */ 1945Svbart@nginx.com } nxt_conf_json_pretty_t; 2045Svbart@nginx.com 2145Svbart@nginx.com 2249Svbart@nginx.com nxt_conf_json_value_t *nxt_conf_json_get_value(nxt_conf_json_value_t *value, 2346Svbart@nginx.com nxt_str_t *path); 2447Svbart@nginx.com nxt_conf_json_value_t *nxt_conf_json_object_get_member( 2551Svbart@nginx.com nxt_conf_json_value_t *value, nxt_str_t *name, uint32_t *index); 2651Svbart@nginx.com 2791Svbart@nginx.com nxt_int_t nxt_conf_json_op_compile(nxt_mp_t *mp, nxt_conf_json_op_t **ops, 2891Svbart@nginx.com nxt_conf_json_value_t *root, nxt_str_t *path, 2991Svbart@nginx.com nxt_conf_json_value_t *value); 3091Svbart@nginx.com nxt_conf_json_value_t *nxt_conf_json_clone_value(nxt_mp_t *mp, 3191Svbart@nginx.com nxt_conf_json_op_t *op, nxt_conf_json_value_t *value); 3251Svbart@nginx.com 3391Svbart@nginx.com nxt_conf_json_value_t *nxt_conf_json_parse(nxt_mp_t *mp, u_char *start, 3491Svbart@nginx.com u_char *end); 3551Svbart@nginx.com 3691Svbart@nginx.com #define nxt_conf_json_str_parse(mp, str) \ 3791Svbart@nginx.com nxt_conf_json_parse(mp, (str)->start, (str)->start + (str)->length) 3891Svbart@nginx.com 39*92Svbart@nginx.com size_t nxt_conf_json_value_length(nxt_conf_json_value_t *value, 40*92Svbart@nginx.com nxt_conf_json_pretty_t *pretty); 41*92Svbart@nginx.com u_char *nxt_conf_json_value_print(u_char *p, nxt_conf_json_value_t *value, 4245Svbart@nginx.com nxt_conf_json_pretty_t *pretty); 4329Svbart@nginx.com 4429Svbart@nginx.com 4529Svbart@nginx.com #endif /* _NXT_CONF_INCLUDED_ */ 46