Allow low-level JSON configuration. see also JSON syntax
◆ plughost_DeleteClient()
Deletes a client
- Parameters
-
| client | the client instance |
◆ plughost_FreeJsonAnswer()
| void plughost_FreeJsonAnswer |
( |
const char * |
json_str | ) |
|
◆ plughost_NewClient()
Creates a new client
- Parameters
-
| instance | the processing instance |
- Returns
- A new client instance
◆ plughost_ProcessJson()
Process a JSON request
For syntax, see JSON syntax
- Note
- In all library, all
char* are UTF-8 encoded
- Attention
- the return value needs to be freed with plughost_FreeJsonAnswer
- Parameters
-
| client | the client instance |
| json_str | the JSON request |
| need_save | on return will be 1 is saving is required (maybe delayed) |
- Returns
- a JSON answer (to be freed with plughost_FreeJsonAnswer)
◆ plughost_SaveState()
Save the current state
Needed when plughost_ProcessJson returned with need_save to 1. However it can be postponed as much as wanted.
- Parameters
-
| instance | the processing instance |
- Returns
- 0 if success, <0 on error