13#define JSMN_PARENT_LINKS
56#ifdef JSMN_PARENT_LINKS
81 jsmntok_t *tokens,
unsigned int num_tokens);
90const char*
GetJSONValue(
jsmntok_t* tokens,
int tokenCount,
const char* json,
int token,
int &valLength);
98const char*
GetJSONValue(
jsmntok_t* tokens,
int tokenCount,
const char* json,
const char* key,
jsmntype_t type,
int &valLength,
int level = 0,
int instance = 0);
114std::string
AddToJSONRoot(
const char* json,
const char* subJSON);
Cross-platform utility toolbox for CMSDK: threading, synchronization, shared memory,...
const char * GetJSONValue(jsmntok_t *tokens, int tokenCount, const char *json, int token, int &valLength)
jsmntype_t
JSON type identifier.
std::string GetJSONChildValueString(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)
const char * GetJSONChildValue(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type, int &valLength)
std::vector< int > GetJSONChildArrayIndexes(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)
std::string GetJSONValueString(jsmntok_t *tokens, int tokenCount, const char *json, int token)
int GetJSONTokenLevel(jsmntok_t *tokens, int startToken)
uint64 GetJSONValueUint64(jsmntok_t *tokens, int tokenCount, const char *json, int token)
int jsmn_parse(jsmn_parser *parser, const char *js, size_t len, jsmntok_t *tokens, unsigned int num_tokens)
Run JSON parser.
std::vector< int > GetJSONArrayIndexes(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, jsmntype_t type=JSMN_UNDEFINED, int level=0, int instance=0)
uint64 GetJSONChildValueUint64(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)
void jsmn_init(jsmn_parser *parser)
Create JSON parser over an array of tokens.
std::string AddToJSONRoot(const char *json, const char *subJSON)
float64 GetJSONChildValueFloat64(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)
int64 GetJSONChildValueInt64(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)
int64 GetJSONValueInt64(jsmntok_t *tokens, int tokenCount, const char *json, int token)
float64 GetJSONValueFloat64(jsmntok_t *tokens, int tokenCount, const char *json, int token)
int GetJSONToken(jsmntok_t *tokens, int tokenCount, const char *json, const char *key, int parent, jsmntype_t type=JSMN_UNDEFINED)