xml and java conversion
Can an开发者_开发百科y one help me out with a java porogram to convert xsd file to xml file.
Thanks in advance.
A XSD file is already an XML file.
XSD is an XML only, XSD specifies the design of XML .
It sounds to me like you want to 'generate' an instance of the XML document, based on the XML Schema.
JAXB (Java Architecture for XML Binding) may be a 'reasonable' way of doing this. By generating a Java Binding from an XSD (input file) it is possible to generate an XML representation of any XML element's defined in the schema (e.g. using the JAXB Marshaller).
Another similar thread may be found on StackOverflow itself: XML instance generation from XML schema (xsd)
Hope this helps! BR/Brian.
XSD is a description of a type of XML document.
an XML Schema (xsd) is a XML file that follows the W3C specification of XML Schemas.
精彩评论