I have a predefined XML schema (XSD file). I need to generate a XML according to that XSD and populate the tag values from
Java Objects...
Right now, there is a built solution that is able to create XML, but the problem is that inside the java code, we are manually creating the XML document and also there is lot of code for appending child tags into the parent tags for creating the XML layout.
The code is unmaintainable.
I am in the process of simplifying this proces...
My question is that is it possible to generate a sample XML from XSD, and use freemarker to populate XML tag values from java objects at runtime...is this a good way to achieve what I intend, or do I need to follow some different path like XSLT or something else.