aspose file tools*
The moose likes XML and Related Technologies and the fly likes Is it possible to generate Java classes from XML? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Is it possible to generate Java classes from XML?" Watch "Is it possible to generate Java classes from XML?" New topic
Author

Is it possible to generate Java classes from XML?

Saurabh Pillai
Ranch Hand

Joined: Sep 12, 2008
Posts: 509
I don't have schema file.

[Edit :- Removed 'JAXB' from subject, I want to be able to generate Java classes from XML using any technology.]
Koen Aerts
Ranch Hand

Joined: Feb 07, 2012
Posts: 344

I don't think it's possible without a schema. Can you generate a schema from the XML with XMLSpy? More info here: http://bitrazor.com/content/tivo/hme/howtos/jaxb/index.php
Saurabh Pillai
Ranch Hand

Joined: Sep 12, 2008
Posts: 509
Thank you Koen. I did go on the same path as you pointed. But I used different tool, XML Schema Definition Tool from Microsoft.

Somehow my company firewall is blocking the page you pointed out saying it is categorized as 'Games'. :-)
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Is it possible to generate Java classes from XML?