Thanks for the info. I checked out JAXB. Getting following error while compiling very simple application. All required jars are in my classpath. xjc item.dtd item.xjs
Error is :"[ERROR] The markup in the document preceding the root element must be well-formed." where following is the content of item.dtd and item.xjs. 1)item.dtd <!ELEMENT item_list (item_info*)> <!ELEMENT item_info (name, price)> <!ELEMENT name (#PCDATA)> <!ELEMENT price (#PCDATA)> 2)item.xjs <?xml version="1.0" encoding="UTF-8"?> <xml-java-binding-schema> <element name="item_list" type="class" root="true"/> <element name="item_info" type="class"/> </xml-java-binding-schema> 3)item.xml <?xml version="1.0" encoding="UTF-8"?> <item_list> <item_info> <name>Pen</name> <price>1.99</price> </item_info> </item_list> I would appreciate any pointers/examples/comments. Thanking you, Vicky "Yee, Richard K,,DMDCWEST" <[EMAIL PROTECTED]> wrote: Check out Castor or Jaxb http://www.castor.org/ http://java.sun.com/xml/jaxb/ -Richard -----Original Message----- From: Vicky [mailto:[EMAIL PROTECTED] Sent: Friday, November 14, 2003 1:33 PM To: [EMAIL PROTECTED] Subject: convert xml into java file Can anyone describe how can i convert .xml file into .java file (with getters and setters). any pointers/resources would be appreciated. Thanks, Vicky --------------------------------- Do you Yahoo!? Protect your identity with Yahoo! Mail AddressGuard --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------- Do you Yahoo!? Protect your identity with Yahoo! Mail AddressGuard