I have to prepare a web service to accept anan already defined wsdl structure. I followed the tutorial found here , with the source code for the test project being downloaded here .
For xsd:
<xs:element name="getCountryRequest"> <xs:complexType> <xs:sequence> <xs:element name="name" type="xs:string"/> </xs:sequence> </xs:complexType> </xs:element>
The Wsdl operation for the request returned by the application in order is as follows:
<wsdl:binding name="CountriesPortSoap11" type="tns:CountriesPort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <wsdl:operation name="getCountry"> <soap:operation soapAction=""/> <wsdl:input name="getCountryRequest"> <soap:body use="literal"/> </wsdl:input> <wsdl:output name="getCountryResponse"> <soap:body use="literal"/> </wsdl:output> </wsdl:operation> </wsdl:binding>
But when I change xsd to (no 'Request' in the element name):
<xs:element name="getCountry"> <xs:complexType> <xs:sequence> <xs:element name="name" type="xs:string"/> </xs:sequence> </xs:complexType> </xs:element>
wsdl is invalid and does not matter <input> :
<wsdl:binding name="CountriesPortSoap11" type="tns:CountriesPort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <wsdl:operation name="getCountry"> <soap:operation soapAction=""/> <wsdl:output name="getCountryResponse"> <soap:body use="literal"/> </wsdl:output> </wsdl:operation> </wsdl:binding>
How can i fix this? How can I make the Request -less element correctly displayed, like entering soap operation in wsdl?
source share