Reputation: 6572
I have a xml and it has a list tag with number of items.
Example:
<param>
<id>12345</id>
<date>2012/07/10</date>
<list>
<item>
<name>Test1</name>
<code>C1</code>
</item>
<item>
<name>Test2</name>
<code>C2</code>
</item>
</list>
</param>
I want to map this in to Java a object using Jakarta Digester framework.
My plan is this.
So after parsing this xml to Jakarta Digester engine I'm expectibg a ResponseDTO with ItemDTO list which are having real values.
Could some one kindly let me know how I can do this using Digester framework.
Upvotes: 0
Views: 3966
Reputation: 7311
Have a look to this article: http://www.devx.com/Java/Article/21832
But there are dozen of XML de/serialization frameworks that are much more user friendly... (http://x-stream.github.io/tutorial.html#init).
M.
Upvotes: 1