我得到了xml输出,然后我将该xml转换为json对象。格式如下。如何在mulesoft中从json中提取JSON数组
{
"SOAP-ENV:Envelope": {
"@xmlns:SOAP-ENV": "http://schemas.xmlsoap.org/soap/envelope/",
"@xmlns:xsi": "http://www.w3.org/2001/XMLSchema-instance",
"@xmlns:xsd": "http://www.w3.org/2001/XMLSchema",
"SOAP-ENV:Body": {
"rpc:TestExampleResponse": {
"@xmlns:rpc": "http://Test.com/asi/",
"TestMessage": {
"listOfTESTS": {
"@xmlns:xmlns": "http://www.Test.com/xml/TEST",
"TESTS": [{
"id": "1",
"lastSyncDate": "12/16/2015 07:06:38",
"listOfTESTsyncrealtimeChild": null
}, {
"id": "2",
"lastSyncDate": "12/16/2015 07:06:38",
"listOfTESTsyncrealtimeChild": null
}
]
}
}
}
}
}
}
我想从JSON输出提取试验阵列Mulesoft.I不知道如何提取mulesoft.Thanks该数组提前
我已经试过的Xpath但得到以下错误执行表达式“xpath3('/ SOAP-ENV:Envelope',有效载荷,'STRING')”失败。 (org.mule.api.expression.ExpressionRuntimeException)。消息有效负载的类型为:字符串 –
由于当前的有效内容不是XML,因此无法使用XPATH。你可以找到[我的答案](http://stackoverflow.com/questions/34647518/how-to-extract-json-array-from-json-in-mulesoft/34649584#34649584)有用 –