I have little strange query here.
I have a sample JSON.
"properties": {
"emailID": {
"type": "string"
},
"createdDate": {
"type": "date"
},
"lastModifiedDate": {
"type": "date"
}
}
I am using GSON here to parse. And I understand I will have to write Properties Class to parse this.
But inside the properties element, all the elements (emailId
, createdDate
, lastModifiedDate
) are dynamic and another JSON
may have 4 objects inside properties element e.g "phoneNumber".
Need help here to write the Properties class such a way that how much properties come inside the Properties element, those are some how converted into object inside the properties object.
Any help or hint will be appreciated. Thanks in Advance!