<?xml version="1.0" encoding="UTF-8"?>
<!--Generated by Oracle BI Publisher -Dataengine, datamodel:_Custom_OAL_ATG_OM_Dashboard_DM_xdm -->
<DATA>
<SUCCESS>
<COUNT___>5686</COUNT___>
</SUCCESS>
<REJECT>
<COUNT___>641</COUNT___>
</REJECT>
<FAILURE>
<COUNT___>8536</COUNT___>
</FAILURE>
<ERROR>
<COUNT___>1447</COUNT___>
</ERROR>
<TERMINATED>
<COUNT___>1341</COUNT___>
</TERMINATED>
</DATA>
以上是我拥有的 XML。我想将上面的 XML 转换为如下所示的 JSON。
{
"appName": "PERFORMANCE",
"statsName": "Status Counts",
"DateBegin": "xxxxxx",
"DateEnd": "xxxxxxx",
"data": {
"SUCCESS ": 1341,
"REJECT":5666, "FAILURE":640,
"ERROR":8515,
"TERMINATED":1447
}
}
我是 XSLT 样式表的新手。有人可以帮我解决上述问题吗?将给定的 XML 转换为 JSON 的 XSLT 样式表是什么?