From: Tatu S. <cow...@ya...> - 2007-01-16 19:45:20
|
What you describe is called data binding. VTD-XML is an xml parser + tree model, and does not handle data binding (xml <-> objects). However, one could build a data binding package on top of it (either for specific use case, hand writing, or a generic system, like JAXB, Castor, XMLBeans, JibX, Betwixt etc). -+ Tatu +- --- ma...@sh... wrote: > I'm new to VTD-XML, and I was wondering if the > following wml could be > converted to java objects using this technology: > > <?xml version="1.0" encoding="UTF-8"?> > <response> > <responseHeader> > <status>0</status><QTime>1</QTime> > </responseHeader> > > <result numFound="2" start="0"> > <doc> > <str name="id">MA147LL/A</str> > <str name="name">Apple 60 GB iPod Black</str> > </doc> > <doc> > <str name="id">EN7800GTX/2DHTV/256M</str> > <str name="name">ASUS Extreme N7800GTX</str> > </doc> > </result> > </response> > > Important are the <str name=" tags, as you see I > need to map them to > object fields based upon their attribute name, can > this be done? > > Grtz > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get > the chance to share your > opinions on IT & business topics through brief > surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Vtd-xml-users mailing list > Vtd...@li... > https://lists.sourceforge.net/lists/listinfo/vtd-xml-users > ____________________________________________________________________________________ Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail beta. http://new.mail.yahoo.com |