API Reference | developer.brewmp.com API Reference | developer.brewmp.com

Developer

API Reference

JSONPARSER_CTOR()

Brew Release
Brew MP 1.0.2
Description

Initializes the JSONParser structure with the provided JSON text string and the size. If size is 0, then string is considered null-terminated.
The caller provides the JSONParser structure. This allows this structure to be stack declared or dynamically declared based on the caller needs. Stack allocation is attractive option for quick parsing needs.
Example: const char *szJSON[] = "{\"company name\" : \"Qualcomm\" }"; JSONParser jp={0}; JSONParser_Ctor(&jp, szJSON, 0);
Params
pj
[]:
JSON context
psz
[]:
JSON data
nSize
[]:
Length of the JSON data passed. Value of 0 means psz is null-terminated.
Interface
Prototype
  •    void   JSONParser_Ctor(JSONParser *pj, const char *psz, int nSize);
     
Return

  • None