23 #ifndef SWITCH_JSON__h 24 #define SWITCH_JSON__h 26 #ifdef FREESWITCHCORE_EXPORTS 27 #ifndef CJSON_EXPORT_SYMBOLS 28 #define CJSON_EXPORT_SYMBOLS 1 32 #ifdef SWITCH_API_VISIBILITY 33 #ifndef CJSON_API_VISIBILITY 34 #define CJSON_API_VISIBILITY 1 51 cJSON *new_json = NULL;
58 new_json = cJSON_CreateObject();
63 cJSON_AddItemToObject(json, name, new_json);
70 cJSON *new_json = NULL;
74 new_json = cJSON_CreateArray();
77 cJSON_AddItemToObject(json, name, new_json);
84 cJSON *new_json = NULL;
88 new_json = cJSON_CreateString(val);
91 cJSON_AddItemToObject(json, name, new_json);
cJSON * cJSON_CreateStringPrintf(const char *fmt,...)
static cJSON * json_add_child_array(cJSON *json, const char *name)
static int cJSON_isTrue(cJSON *json)
static cJSON * json_add_child_obj(cJSON *json, const char *name, cJSON *obj)
const char * cJSON_GetObjectCstr(const cJSON *object, const char *string)
static cJSON * json_add_child_string(cJSON *json, const char *name, const char *val)