nRF Connect SDK API 0.1.0
|
void json_add_obj | ( | cJSON * | parent, |
const char * | str, | ||
cJSON * | item | ||
) |
Associate a child object with a parent.
This API is expected to be called after data has been added to the child item. If this API fails to add the child item to the parent it will free the child item. Due to this its not guaranteed that subsequent accesses to the child item will succeed after this API call.
[in,out] | parent | Pointer to a parent object. |
[in] | str | Name of the added child object. |
[in] | item | Pointer to child object. |