Question & Answer
Question
How to get an Api template as a Document Object
Answer
Consider that callDSWApi is a custom class and extn_myOrderDetails is the xml to be set for the same. Ensure that the xml is present in the 'same folder/jar' as the custom class instead of the "template\api\extn\" folder. Now for getting the template as a Document Object the following code can be used: YFCDocument tempdoc = YFCDocument.parse(callDSWApi.class.getResourceAsStream("/extn_myOrderDetails.xml "))
[{"Product":{"code":"SS6PEW","label":"IBM Sterling Order Management"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]
Historical Number
HTG3282
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg21562805