Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

XML directly to java classes  RSS feed

 
Petr Blahos
Ranch Hand
Posts: 131
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I was wondering if there is a library that will allow me read
xml directly into a structure of Java classes. Example:
Let's have an xml:

And java classes:

This library would read the xml and build the corresponding
structure of classes. Any hints?

Thanks, Petr
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Take a look at XStream.
 
Daniel Mayer
Ranch Hand
Posts: 103
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Alternatives are http://www.castor.org/ and http://jakarta.apache.org/commons/digester/
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!