Non-problematic XML-to-Java binding

start84

New Member
I've looked all over the place for a good way to bind XML elements to Java classes. It sounds like a fairly easy thing to implement (for some value of easy), but wherever I look, there's the need for XSDs, explicit mapping and a bunch of other things that really get in the way for me.This is my (possibly incomplete) idea of a Java object representing a sitemap.\[code\]public class Sitemap { private List<Url> urls; public List<Url> getUrls() { return urls; } public void setUrls(List<Url> urls) { this.urls = urls; }}\[/code\]I'm looking for something which lets me do:\[code\]Sitemap sitemap = (Sitemap) Foo.fromXml("sitemap.xml")\[/code\]Something like that, or at least similar. Is there any such thing?
 
Back
Top