Creating complex JSON objects and accessing elements within
Hi,
I have been reading the posts and the documentation around JSON support available with 2016.2 (which is my version) and following versions, but haven't found a concrete example of how to design and implement a complex JSON entity object. I'm working on creating a REST client to connect to an external service and working on modeling the request and response objects, but keep running into invalid OREF when trying to access elements. I've tried creating a container class 'request', which extends
Here is an example of the JSON I'm hoping to model into a class:
{
"tag": "post",
"body": {
"patient": {
"site": [{
"code": "string",
"mrn": "string"
}
],
"email": ["string"],
"addresses": [{
"line1": "string",
"line2": "string",
"city": "string",
"state": "string",
"postalCode": "string"
}
],
"names": [{
"first": "string",
"middle": "string",
"last": "string",
"suffix": "string"
}
]
}
}
}