Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How to setup HMap to be able to create the XML from the following JSON?
Input JSON
{
"documentSection":{
"documentStatus": 1,
"documentNumber": "9300806055"
},
"partnerSection": {
"partner_role_ag": {
"partnerRole": "AG",
"contactFirstName": "Mario"
},
"partner_role_lf": {
"partnerRole": "LF",
"contactFirstName": "Anna"
},
"partner_role_we": {
"partnerRole": "WE",
"contactFirstName": "Mia"
}
}
}
Output XML:
<ORDER> <HEAD> <DOC_STATUS>1</DOC_STATUS> <DOC_NO>9300806055</DOC_NO> <PARTY> <PARTNER_ROLE>AG</PARTNER_ROLE> <NAME1>Mario</NAME1> </PARTY> <PARTY> <PARTNER_ROLE>LF</PARTNER_ROLE> <NAME1>Anna</NAME1> </PARTY> <PARTY> <PARTNER_ROLE>WE</PARTNER_ROLE> <NAME1>Mia</NAME1> </PARTY> </HEAD> </ORDER>
Hi,
How do you get this JSON input ? Do you read it on a file system ? Does it come from a webservice call ? ...
Eric
web service call, but why does that matter?