JSON_ObjectGetObject
%JSON_ObjectGetObject function
Function
Gets an object in the field from the JSON object.
Declaration
INT %JSON_ObjectGetObject(
INT in handle,
TEXT in field
)Parameters
handle | Handle to parent JSON object. |
field | Field name |
Return value
Handle to the JSON object, must be released by %JSON_FreeObjectHandle.
Description
Funciton gets an array in the field from the JSON object.
Exception is thrown if object at index is not array, handle to JSON object is invalid or the field does not exists.
Example
INT _obj
_obj := %JSON_ObjectFromString(ModuleInfo)
INT _tmp
_tmp := %JSON_ObjectGetObject(_obj, "client_info")
%JSON_FreeObjectHandle(_obj)
%JSON_FreeObjectHandle(_tmp)