xml 传输数据如何处理更好
项目要使用xml传输数据,例如:
<logisticsEventsRequest>
<logisticsEvent>
<eventHeader>
<eventType> LOGISTICS _TMS_CONFIRM_DUTYS </eventType>
<eventTime>2013-08-24 08:00:00</eventTime>
<eventSource> STORECODE </eventSource>
<eventTarget>CP</eventTarget>
</eventHeader>
<eventBody>
<logisticsDetail>
<logisticsOrders>
<logisticsOrder>
<poNo>LP682343244</ poNo >
<occurTime>2013-03-08</occurTime>
<confirmPaymethod>A</confirmPaymethod >
<logisticsRemark>扣款后请放行</logisticsRemark>
</logisticsOrder>
</logisticsOrders>
</logisticsDetail>
</eventBody>
</logisticsEvent>
</logisticsEventsRequest>
xml 的内容要构建,如果传输 json,直接创建对象然后转换json,现在要传输xml,有什么方便的方式么?