Saturday, February 5, 2011

What is the best way to generate XML Binding Code from a DTD?

Most Java-XML binding frameworks and code generators need XML Schema Defintions. Can you suggest the best way to generate binding code from DTD.

I know that the XJC in JAXB 2 supports DTD but it is considered experimental.

In the spirit of Stack Overflow, one suggestion per answer please - to be voted up or down instead of duplicated

  • Convert the DTD to a schema (lots of online and offline tools available). This step should be lossless. Now use this schema with your favorite Java-XML binding framework and/or code generator that needs schema definitions.

    From GerG

0 comments:

Post a Comment