Topic: (急)web service 发送消息时axis解析的xml的xml string的名域产生错误

  Print this page

1.(急)web service 发送消息时axis解析的xml的xml string的名域产生错误 Copy to clipboard
Posted by: jorrey
Posted on: 2006-09-10 17:41

开发环境:
jdk1.4.2
jbuilder2005
axis1.3(或1.4)

KFWebService.wsdl文件为web service服务器接口
res.xml为发送的xml串为:
<?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><soapenv:Body><ns1:Zc2IntessHandle soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="urn:KFWebService"><Zc2IntessHandle href="#id0"/></ns1:Zc2IntessHandle><multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns2:TagZc2IntessHandle" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns2="urn:KFWebService"><id xsi:type="xsd:string">830</id><status xsi:type="xsd:string">4</status><dept xsi:type="xsd:string">帮助台</dept><handleno xsi:type="xsd:string">FWPT</handleno><procTime xsi:type="xsd:string"></procTime><content xsi:type="xsd:string">事件单处理状态为:分配到帮助台.处理部门为:帮助台.处理人为:</content><attachName xsi:type="xsd:string"></attachName><attachURL xsi:type="xsd:string"></attachURL></multiRef></soapenv:Body></soapenv:Envelope>

出现的错误为:
<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns="urn:KFWebService"><SOAP-ENV:Body SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Fault><faultcode>SOAP-ENV:Client</faultcode><faultstring>Data type 'ns2:TagZc2IntessHandle' mismatch in element 'multiRef'</faultstring></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>

分析:
为什么在send的xml中存在ns1:Zc2IntessHandle 和ns2:Zc2IntessHandle ,而不是ns:Zc2IntessHandle

KFWebService.wsdl (10.57k)

2.Re:(急)web service 发送消息时axis解析的xml的xml string的名域产生错误 [Re: jorrey] Copy to clipboard
Posted by: jorrey
Posted on: 2006-09-10 19:34

顶一下,哪位高手帮一下忙!

3.Re:(急)web service 发送消息时axis解析的xml的xml string的名域产生错误 [Re: jorrey] Copy to clipboard
Posted by: jorrey
Posted on: 2006-09-11 09:22

再顶一次


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923