File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

creating objects from an XML file

 
lupercal hill
Greenhorn
Posts: 9
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to pull data from an XML file and place it in a java object. Im using SAX to parse the file .

Do I need to wrap XML data in an objectinputstream method to use the values?
 
Paul Clapham
Sheriff
Pie
Posts: 20163
24
MySQL Database
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
An ObjectInputStream???

No. You get data from SAX as strings. Those strings may be element names or attribute values or text nodes or whatever. You can use normal Java programming techniques to create objects that contain those strings.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic