modbusd
modbus master daemon
|
#include "stdint.h"
Go to the source code of this file.
Data Structures | |
struct | cJSON |
struct | cJSON_Hooks |
Macros | |
#define | cJSON_False (1 << 0) |
#define | cJSON_True (1 << 1) |
#define | cJSON_NULL (1 << 2) |
#define | cJSON_Number (1 << 3) |
#define | cJSON_String (1 << 4) |
#define | cJSON_Array (1 << 5) |
#define | cJSON_Object (1 << 6) |
#define | cJSON_IsReference 256 |
#define | cJSON_StringIsConst 512 |
#define | cJSON_AddNullToObject(object, name) cJSON_AddItemToObject(object, name, cJSON_CreateNull()) |
#define | cJSON_AddTrueToObject(object, name) cJSON_AddItemToObject(object, name, cJSON_CreateTrue()) |
#define | cJSON_AddFalseToObject(object, name) cJSON_AddItemToObject(object, name, cJSON_CreateFalse()) |
#define | cJSON_AddBoolToObject(object, name, b) cJSON_AddItemToObject(object, name, cJSON_CreateBool(b)) |
#define | cJSON_AddNumberToObject(object, name, n) cJSON_AddItemToObject(object, name, cJSON_CreateNumber(n)) |
#define | cJSON_AddStringToObject(object, name, s) cJSON_AddItemToObject(object, name, cJSON_CreateString(s)) |
#define | cJSON_SetIntValue(object, val) ((object)?(object)->valueint=(object)->valuedouble=(val):(val)) |
#define | cJSON_SetNumberValue(object, val) ((object)?(object)->valueint=(object)->valuedouble=(val):(val)) |
#define | cJSON_ArrayForEach(pos, head) for(pos = (head)->child; pos != NULL; pos = pos->next) |
Typedefs | |
typedef struct cJSON | cJSON |
typedef struct cJSON_Hooks | cJSON_Hooks |
Functions | |
void | cJSON_InitHooks (cJSON_Hooks *hooks) |
cJSON * | cJSON_Parse (const char *value) |
char * | cJSON_Print (cJSON *item) |
char * | cJSON_PrintUnformatted (cJSON *item) |
char * | cJSON_PrintBuffered (cJSON *item, int prebuffer, int fmt) |
void | cJSON_Delete (cJSON *c) |
int | cJSON_GetArraySize (cJSON *array) |
cJSON * | cJSON_GetArrayItem (cJSON *array, int item) |
cJSON * | cJSON_GetObjectItem (cJSON *object, const char *string) |
int | cJSON_HasObjectItem (cJSON *object, const char *string) |
const char * | cJSON_GetErrorPtr (void) |
cJSON * | cJSON_CreateNull (void) |
cJSON * | cJSON_CreateTrue (void) |
cJSON * | cJSON_CreateFalse (void) |
cJSON * | cJSON_CreateBool (int b) |
cJSON * | cJSON_CreateNumber (double num) |
cJSON * | cJSON_CreateString (const char *string) |
cJSON * | cJSON_CreateArray (void) |
cJSON * | cJSON_CreateObject (void) |
cJSON * | cJSON_CreateUInt8Array (const uint8_t *numbers, int count) |
cJSON * | cJSON_CreateUInt16Array (const uint16_t *numbers, int count) |
cJSON * | cJSON_CreateIntArray (const int *numbers, int count) |
cJSON * | cJSON_CreateFloatArray (const float *numbers, int count) |
cJSON * | cJSON_CreateDoubleArray (const double *numbers, int count) |
cJSON * | cJSON_CreateStringArray (const char **strings, int count) |
void | cJSON_AddItemToArray (cJSON *array, cJSON *item) |
void | cJSON_AddItemToObject (cJSON *object, const char *string, cJSON *item) |
void | cJSON_AddItemToObjectCS (cJSON *object, const char *string, cJSON *item) |
void | cJSON_AddItemReferenceToArray (cJSON *array, cJSON *item) |
void | cJSON_AddItemReferenceToObject (cJSON *object, const char *string, cJSON *item) |
cJSON * | cJSON_DetachItemFromArray (cJSON *array, int which) |
void | cJSON_DeleteItemFromArray (cJSON *array, int which) |
cJSON * | cJSON_DetachItemFromObject (cJSON *object, const char *string) |
void | cJSON_DeleteItemFromObject (cJSON *object, const char *string) |
void | cJSON_InsertItemInArray (cJSON *array, int which, cJSON *newitem) |
void | cJSON_ReplaceItemInArray (cJSON *array, int which, cJSON *newitem) |
void | cJSON_ReplaceItemInObject (cJSON *object, const char *string, cJSON *newitem) |
cJSON * | cJSON_Duplicate (cJSON *item, int recurse) |
cJSON * | cJSON_ParseWithOpts (const char *value, const char **return_parse_end, int require_null_terminated) |
void | cJSON_Minify (char *json) |
#define cJSON_AddBoolToObject | ( | object, | |
name, | |||
b | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateBool(b)) |
#define cJSON_AddFalseToObject | ( | object, | |
name | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateFalse()) |
#define cJSON_AddNullToObject | ( | object, | |
name | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateNull()) |
#define cJSON_AddNumberToObject | ( | object, | |
name, | |||
n | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateNumber(n)) |
Referenced by mbtcp_get_response_timeout(), and test_json_encode().
#define cJSON_AddStringToObject | ( | object, | |
name, | |||
s | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateString(s)) |
#define cJSON_AddTrueToObject | ( | object, | |
name | |||
) | cJSON_AddItemToObject(object, name, cJSON_CreateTrue()) |
#define cJSON_Array (1 << 5) |
#define cJSON_ArrayForEach | ( | pos, | |
head | |||
) | for(pos = (head)->child; pos != NULL; pos = pos->next) |
#define cJSON_False (1 << 0) |
Referenced by cJSON_CreateBool(), and cJSON_CreateFalse().
#define cJSON_IsReference 256 |
Referenced by cJSON_Delete(), and cJSON_Duplicate().
#define cJSON_NULL (1 << 2) |
Referenced by cJSON_CreateNull(), and cJSONUtils_MergePatch().
#define cJSON_Number (1 << 3) |
Referenced by cJSON_CreateNumber(), cJSON_CreateUInt16(), and cJSON_CreateUInt8().
#define cJSON_Object (1 << 6) |
#define cJSON_SetIntValue | ( | object, | |
val | |||
) | ((object)?(object)->valueint=(object)->valuedouble=(val):(val)) |
#define cJSON_SetNumberValue | ( | object, | |
val | |||
) | ((object)?(object)->valueint=(object)->valuedouble=(val):(val)) |
#define cJSON_String (1 << 4) |
Referenced by cJSON_CreateString().
#define cJSON_StringIsConst 512 |
Referenced by cJSON_AddItemToObjectCS(), and cJSON_Delete().
#define cJSON_True (1 << 1) |
Referenced by cJSON_CreateBool(), and cJSON_CreateTrue().
typedef struct cJSON_Hooks cJSON_Hooks |
References cJSON_AddItemToObject().
References cJSON::child, and cJSON::next.
Referenced by cJSON_AddItemReferenceToArray(), cJSON_AddItemToObject(), cJSON_AddItemToObjectCS(), and cJSON_InsertItemInArray().
References cJSON_AddItemToArray(), and cJSON::string.
Referenced by cJSON_AddItemReferenceToObject(), cJSONUtils_GenerateMergePatch(), cJSONUtils_MergePatch(), set_modbus_success_resp_str_with_data(), and test_json_encode().
References cJSON_AddItemToArray(), cJSON_StringIsConst, cJSON::string, and cJSON::type.
cJSON* cJSON_CreateArray | ( | void | ) |
References cJSON_Array, and cJSON::type.
Referenced by cJSON_CreateDoubleArray(), cJSON_CreateFloatArray(), cJSON_CreateIntArray(), cJSON_CreateStringArray(), cJSON_CreateUInt16Array(), cJSON_CreateUInt8Array(), and cJSONUtils_GeneratePatches().
cJSON* cJSON_CreateBool | ( | int | b | ) |
References cJSON_False, cJSON_True, and cJSON::type.
cJSON* cJSON_CreateDoubleArray | ( | const double * | numbers, |
int | count | ||
) |
References cJSON_CreateArray(), cJSON_CreateNumber(), and cJSON_Delete().
cJSON* cJSON_CreateFalse | ( | void | ) |
References cJSON_False, and cJSON::type.
cJSON* cJSON_CreateFloatArray | ( | const float * | numbers, |
int | count | ||
) |
References cJSON_CreateArray(), cJSON_CreateNumber(), and cJSON_Delete().
cJSON* cJSON_CreateIntArray | ( | const int * | numbers, |
int | count | ||
) |
References cJSON_CreateArray(), cJSON_CreateNumber(), and cJSON_Delete().
Referenced by test_json_encode().
cJSON* cJSON_CreateNull | ( | void | ) |
References cJSON_NULL, and cJSON::type.
Referenced by cJSONUtils_GenerateMergePatch().
cJSON* cJSON_CreateNumber | ( | double | num | ) |
References cJSON_Number, cJSON::type, cJSON::valuedouble, and cJSON::valueint.
Referenced by cJSON_CreateDoubleArray(), cJSON_CreateFloatArray(), and cJSON_CreateIntArray().
cJSON* cJSON_CreateObject | ( | void | ) |
References cJSON_Object, and cJSON::type.
Referenced by cJSONUtils_GenerateMergePatch(), cJSONUtils_MergePatch(), mbtcp_get_response_timeout(), mbtcp_set_response_timeout(), set_modbus_fail_resp_str(), set_modbus_success_resp_str_with_data(), and test_json_encode().
cJSON* cJSON_CreateString | ( | const char * | string | ) |
References cJSON_Delete(), cJSON_String, cJSON::type, and cJSON::valuestring.
Referenced by cJSON_CreateStringArray().
cJSON* cJSON_CreateStringArray | ( | const char ** | strings, |
int | count | ||
) |
References cJSON_CreateArray(), cJSON_CreateString(), and cJSON_Delete().
cJSON* cJSON_CreateTrue | ( | void | ) |
References cJSON_True, and cJSON::type.
cJSON* cJSON_CreateUInt16Array | ( | const uint16_t * | numbers, |
int | count | ||
) |
References cJSON_CreateArray(), cJSON_CreateUInt16(), and cJSON_Delete().
Referenced by mbtcp_read_reg_req_fn().
References cJSON_CreateArray(), cJSON_CreateUInt8(), and cJSON_Delete().
Referenced by mbtcp_read_bit_req_fn().
void cJSON_Delete | ( | cJSON * | c | ) |
References cJSON::child, cJSON_Delete(), cJSON_IsReference, cJSON_StringIsConst, cJSON::next, cJSON::string, cJSON::type, and cJSON::valuestring.
Referenced by cJSON_CreateDoubleArray(), cJSON_CreateFloatArray(), cJSON_CreateIntArray(), cJSON_CreateString(), cJSON_CreateStringArray(), cJSON_CreateUInt16Array(), cJSON_CreateUInt8Array(), cJSON_Delete(), cJSON_DeleteItemFromArray(), cJSON_DeleteItemFromObject(), cJSON_Duplicate(), cJSON_ParseWithOpts(), cJSON_ReplaceItemInArray(), cJSONUtils_GenerateMergePatch(), cJSONUtils_MergePatch(), main(), mbtcp_get_response_timeout(), mbtcp_set_response_timeout(), set_modbus_fail_resp_str(), set_modbus_success_resp_str_with_data(), test_json_decode(), and test_json_encode().
void cJSON_DeleteItemFromArray | ( | cJSON * | array, |
int | which | ||
) |
References cJSON_Delete(), and cJSON_DetachItemFromArray().
void cJSON_DeleteItemFromObject | ( | cJSON * | object, |
const char * | string | ||
) |
References cJSON_Delete(), and cJSON_DetachItemFromObject().
Referenced by cJSONUtils_MergePatch().
References cJSON::child, cJSON::next, and cJSON::prev.
Referenced by cJSON_DeleteItemFromArray(), and cJSON_DetachItemFromObject().
References cJSON::child, cJSON_DetachItemFromArray(), cJSON::next, and cJSON::string.
Referenced by cJSON_DeleteItemFromObject(), and cJSONUtils_MergePatch().
References cJSON::child, cJSON_Delete(), cJSON_Duplicate(), cJSON_IsReference, cJSON::next, cJSON::prev, cJSON::string, cJSON::type, cJSON::valuedouble, cJSON::valueint, and cJSON::valuestring.
Referenced by cJSON_Duplicate(), cJSONUtils_GenerateMergePatch(), and cJSONUtils_MergePatch().
References cJSON::child, and cJSON::next.
Referenced by cJSONUtils_GetPointer(), mbtcp_multi_write_req_fn(), and test_json_decode().
int cJSON_GetArraySize | ( | cJSON * | array | ) |
References cJSON::child, and cJSON::next.
Referenced by mbtcp_multi_write_req_fn(), and test_json_decode().
References cJSON::child, cJSON::next, and cJSON::string.
Referenced by cJSON_HasObjectItem(), json_get_char(), json_get_double(), json_get_int(), json_get_long(), json_set_double(), json_set_int(), mbtcp_multi_write_req_fn(), and test_json_decode().
int cJSON_HasObjectItem | ( | cJSON * | object, |
const char * | string | ||
) |
References cJSON_GetObjectItem().
void cJSON_InitHooks | ( | cJSON_Hooks * | hooks | ) |
References cJSON_Hooks::free_fn, and cJSON_Hooks::malloc_fn.
References cJSON::child, cJSON_AddItemToArray(), cJSON::next, and cJSON::prev.
void cJSON_Minify | ( | char * | json | ) |
cJSON* cJSON_Parse | ( | const char * | value | ) |
References cJSON_ParseWithOpts().
Referenced by file_to_json(), main(), and test_json_decode().
cJSON* cJSON_ParseWithOpts | ( | const char * | value, |
const char ** | return_parse_end, | ||
int | require_null_terminated | ||
) |
References cJSON_Delete().
Referenced by cJSON_Parse().
char* cJSON_Print | ( | cJSON * | item | ) |
Referenced by json_to_file(), test_json_decode(), and test_json_encode().
char* cJSON_PrintBuffered | ( | cJSON * | item, |
int | prebuffer, | ||
int | fmt | ||
) |
References printbuffer::buffer, printbuffer::length, and printbuffer::offset.
char* cJSON_PrintUnformatted | ( | cJSON * | item | ) |
Referenced by mbtcp_get_response_timeout(), mbtcp_set_response_timeout(), set_modbus_fail_resp_str(), and set_modbus_success_resp_str_with_data().
References cJSON::child, cJSON_Delete(), cJSON::next, and cJSON::prev.
Referenced by cJSON_ReplaceItemInObject().
References cJSON::child, cJSON_ReplaceItemInArray(), cJSON::next, and cJSON::string.