Reputation: 1
I am using WID 8.5. I have two service message objects, which contain complex type array. I am trying to get these arrays into my java code and compare the values in both arrays. Based on the comparison, I have to create new array and store it into new service message object. I am getting these arrays using NodeList.
Please find the BO details here.
SMO1 <metadata> <values> <desc>client country</desc> <key>India<key> <values> <values> <desc>client name</desc> <key>Satish<key> <values> <metadata> SMO2 <metadata> <values> <desc>client name</desc> <key>123<key> <values> <values> <desc>client country</desc> <key>124<key> <values> <metadata> Final SMO <metadata> <values> <desc>client name</desc> <key>123<key> <values>Satish</value> </values> <values> <desc>client country</desc> <key>124<key> <value>India</value> </values> <metadata>
Please provide me custom java code to accomplish this transformation.
Upvotes: 0
Views: 478
Reputation: 49
Get whatever elements you want using smo getter methods from smo1 and smo2
Ex:smo.getString(xpath of the smo)
Build a data object with all the elements you got in the first step
Add this data object to the Final smo
Upvotes: 0