Web services 错误:找到以元素开头的无效内容。此时不需要任何子元素
我的web服务有一个错误。 错误是: 发现以元素“callerNumber”开头的无效内容。此时不需要任何子元素 服务send The object RelationCARO包含3个字符串:caName、roName和callerNumber(可选) 当callerNumber为NULL时,它工作;当callerNumber不为NULL时,我有上述错误 当我尝试使用soapUI调用服务时,它甚至可以使用callerNumber WSDL:Web services 错误:找到以元素开头的无效内容。此时不需要任何子元素,web-services,wsdl,wsdl2java,Web Services,Wsdl,Wsdl2java,我的web服务有一个错误。 错误是: 发现以元素“callerNumber”开头的无效内容。此时不需要任何子元素 服务send The object RelationCARO包含3个字符串:caName、roName和callerNumber(可选) 当callerNumber为NULL时,它工作;当callerNumber不为NULL时,我有上述错误 当我尝试使用soapUI调用服务时,它甚至可以使用callerNumber WSDL: <?xml version='1.0' encod
<?xml version='1.0' encoding='UTF-8'?><wsdl:definitions name="RMDManagementService" targetNamespace="http://ws.mom.rmd.atos.net/ws" xmlns:ns1="http://cxf.apache.org/bindings/xformat" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://ws.mom.rmd.atos.net/ws" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:types>
<xs:schema elementFormDefault="unqualified" targetNamespace="http://ws.mom.rmd.atos.net/ws" version="1.0" xmlns:tns="http://ws.mom.rmd.atos.net/ws" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="createRelationCaRo" type="tns:createRelationCaRo" />
<xs:element name="createRelationCaRoResponse" type="tns:createRelationCaRoResponse" />
<xs:complexType name="createRelationCaRo">
<xs:sequence>
<xs:element minOccurs="0" name="relationCaRo" type="tns:relationCaRo" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="relationCaRo">
<xs:sequence>
<xs:element minOccurs="0" name="caName" type="xs:string" />
<xs:element minOccurs="0" name="roName" type="xs:string" />
<xs:element minOccurs="0" name="callerNumber" type="xs:string" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="createRelationCaRoResponse">
<xs:sequence>
<xs:element minOccurs="0" name="return" type="tns:relationCaRoFeedback" />
</xs:sequence>
</xs:complexType>
<xs:complexType name="relationCaRoFeedback">
<xs:sequence>
<xs:element minOccurs="0" name="caName" type="xs:string" />
<xs:element minOccurs="0" name="roName" type="xs:string" />
<xs:element minOccurs="0" name="statusReturnCode" type="tns:statusReturnCodeEnum" />
</xs:sequence>
</xs:complexType>
<xs:simpleType name="statusReturnCodeEnum">
<xs:restriction base="xs:string">
<xs:enumeration value="CDE_RMD000" />
<xs:enumeration value="CDE_RMD001" />
<xs:enumeration value="CDE_RMD300" />
<xs:enumeration value="CDE_RMD303" />
<xs:enumeration value="CDE_RMD304" />
</xs:restriction>
</xs:simpleType>
</xs:schema>
</wsdl:types>
<wsdl:message name="createRelationCaRo">
<wsdl:part element="tns:createRelationCaRo" name="parameters">
</wsdl:part>
</wsdl:message>
<wsdl:message name="createRelationCaRoResponse">
<wsdl:part element="tns:createRelationCaRoResponse" name="parameters">
</wsdl:part>
</wsdl:message>
<wsdl:portType name="RMDManagement">
<wsdl:operation name="createRelationCaRo">
<wsdl:input message="tns:createRelationCaRo" name="createRelationCaRo">
</wsdl:input>
<wsdl:output message="tns:createRelationCaRoResponse" name="createRelationCaRoResponse">
</wsdl:output>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="RMDManagementServiceSoapBinding" type="tns:RMDManagement">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
<wsdl:operation name="createRelationCaRo">
<soap:operation soapAction="" style="document" />
<wsdl:input name="createRelationCaRo">
<soap:body use="literal" />
</wsdl:input>
<wsdl:output name="createRelationCaRoResponse">
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="RMDManagementService">
<wsdl:port binding="tns:RMDManagementServiceSoapBinding" name="RMDManagementSOAPPort">
<soap:address location="http://...../RMDManagementService" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
在客户端,我使用wsdl2java生成了所有类
我不理解这个问题,因为只有3个字符串,参数中没有子元素
谢谢您的帮助。您的wsdl非常好。
请将您的代码张贴在此处(还包括消息上下文部分和soap信封创建),我无法解决您的问题。谢谢您的帮助。我把代码放在这个地址上:伙计,这个链接是什么(。请把代码贴在这里。它看起来像垃圾邮件网站。悲伤。