Simple Java Xml to POJO mapping/binding?

后端 未结 4 1870
一向
一向 2020-12-10 05:41

I\'m trying to figure out the simplest way to map an xml file to to a plain old java object.

Note: That in my example the xml doesn\'t quite match up with my intend

4条回答
  •  甜味超标
    2020-12-10 06:05

    Jakarta Commons Digester should do what you want.

    Alternatively, I would recommend writing a transformation class that uses XPath to retrieve elements from the XML.

提交回复
热议问题