Mule: Is there simple way of converting XML to JSON

前端 未结 4 834
一向
一向 2020-12-10 19:51

Is there simple way of converting XML to JSON, without binding XML to a java object first?

Just like how this does it -- http://www.utilities-online.info/xmltojson/

4条回答
  •  情深已故
    2020-12-10 20:10

    You can build a custom transformer[1] based on json-lib[2].

    [1] http://www.mulesoft.org/documentation/display/current/Creating+Custom+Transformers

    [2] http://json-lib.sourceforge.net/

提交回复
热议问题