This WSDL is an example of how not to build an interoperable web
service in .NET. This service returns a .NET DataSet data type --
hence the schema included in the response message. I know of no
Java-based SOAP framework that can process one of these automatically.
Your best option is too toss the service back at the folks that
provided it and tell them to implement an interoperable service that
does not return proprietary data types like the DataSet. Your only
other option is to use the messaging API and process the response
message (and its embedded schema) using DOM.

Anne

On 9/18/07, Dean Pullen <[EMAIL PROTECTED]> wrote:
>
>
>
>
> Hi all.
>
>
>
> Maybe I'm in need of further reading, maybe someone can point me in the
> right direction.
>
>
>
> I've used Axis to generate client side stubs before, but I've never worked
> with a) a .NET service and b) a service that wasn't our own, and I'm having
> a few issues understanding what I need to do. Hopefully someone can help.
>
>
>
> I have a WSDL definition from a .NET service, below is an edited version (to
> allow for anonymity):
>
>
>
> <wsdl:definitions
> xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
> xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/";
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
> xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/";
> xmlns:tns="http://tempuri.org//TPI";
> xmlns:s="http://www.w3.org/2001/XMLSchema";
> xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/";
> xmlns:http="http://schemas.xmlsoap.org/wsdl/http/";
> targetNamespace="http://tempuri.org//TPI";
> xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
>
>   <wsdl:types>
>
>     <s:schema elementFormDefault="qualified"
> targetNamespace="http://tempuri.org//TPI";>
>
>       <s:element name="ConfirmRedirection">
>
>         <s:complexType>
>
>           <s:sequence>
>
>             <s:element minOccurs="0" maxOccurs="1" name="SessionID"
> type="s:string" />
>
>             <s:element minOccurs="0" maxOccurs="1" name="INET4UserID"
> type="s:string" />
>
>           </s:sequence>
>
>         </s:complexType>
>
>       </s:element>
>
>       <s:element name="ConfirmRedirectionResponse">
>
>         <s:complexType>
>
>           <s:sequence>
>
>             <s:element minOccurs="0" maxOccurs="1"
> name="ConfirmRedirectionResult">
>
>               <s:complexType>
>
>                 <s:sequence>
>
>                   <s:element ref="s:schema" />
>
>                   <s:any />
>
>                 </s:sequence>
>
>               </s:complexType>
>
>             </s:element>
>
>           </s:sequence>
>
>         </s:complexType>
>
>       </s:element>
>
>     </s:schema>
>
>   </wsdl:types>
>
>   <wsdl:message name="ConfirmRedirectionSoapIn">
>
>     <wsdl:part name="parameters"
> element="tns:ConfirmRedirection" />
>
>   </wsdl:message>
>
>   <wsdl:message name="ConfirmRedirectionSoapOut">
>
>     <wsdl:part name="parameters"
> element="tns:ConfirmRedirectionResponse" />
>
>   </wsdl:message>
>
>   <wsdl:portType name="TPISoap">
>
>     <wsdl:operation name="ConfirmRedirection">
>
>       <wsdl:input message="tns:ConfirmRedirectionSoapIn" />
>
>       <wsdl:output message="tns:ConfirmRedirectionSoapOut"
> />
>
>     </wsdl:operation>
>
>   </wsdl:portType>
>
>   <wsdl:binding name="TPISoap" type="tns:TPISoap">
>
>     <soap:binding
> transport="http://schemas.xmlsoap.org/soap/http"; />
>
>     <wsdl:operation name="ConfirmRedirection">
>
>       <soap:operation
> soapAction="http://tempuri.org//TPI/ConfirmRedirection";
> style="document" />
>
>       <wsdl:input>
>
>         <soap:body use="literal" />
>
>       </wsdl:input>
>
>       <wsdl:output>
>
>         <soap:body use="literal" />
>
>       </wsdl:output>
>
>     </wsdl:operation>
>
>   </wsdl:binding>
>
>   <wsdl:binding name="TPISoap12" type="tns:TPISoap">
>
>     <soap12:binding
> transport="http://schemas.xmlsoap.org/soap/http"; />
>
>     <wsdl:operation name="ConfirmRedirection">
>
>       <soap12:operation
> soapAction="http://tempuri.org//TPI/ConfirmRedirection";
> style="document" />
>
>       <wsdl:input>
>
>         <soap12:body use="literal" />
>
>       </wsdl:input>
>
>       <wsdl:output>
>
>         <soap12:body use="literal" />
>
>       </wsdl:output>
>
>     </wsdl:operation>
>
>   </wsdl:binding>
>
>   <wsdl:service name="TPI">
>
>     <wsdl:port name="TPISoap" binding="tns:TPISoap">
>
>       <soap:address location="http://www.domain.com/tpi.asmx"; />
>
>     </wsdl:port>
>
>     <wsdl:port name="TPISoap12" binding="tns:TPISoap12">
>
>       <soap12:address location="http://www.domain.com/tpi.asmx"; />
>
>     </wsdl:port>
>
>   </wsdl:service>
>
> </wsdl:definitions>
>
>
>
> This would allegedly provide a response like so:
>
>   <?xml version="1.0" encoding="utf-8"?>
> <soap12:Envelope
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xmlns:xsd="http://www.w3.org/2001/XMLSchema";
> xmlns:soap12="http://www.w3.org/2003/05/soap-envelope";>
>   <soap12:Body>
>     <ConfirmRedirectionResponse xmlns="http://tempuri.org//TPI";>
>       <ConfirmRedirectionResult>
>
> <xsd:schema>schema</xsd:schema>xml</ConfirmRedirectionResult>
>     </ConfirmRedirectionResponse>
>   </soap12:Body>
> </soap12:Envelope>
>
>
>   Where 'schema' and 'xml' in this line:
> <xsd:schema>schema</xsd:schema>xml</ConfirmRedirectionResult>
> are 'placeholders'.
>
> Now I'm expecting a lot of user data to come back in this response, and I
> presume that it will come within these placeholders.
> If that's correct how do I generate a client stub using Axis that represents
> this service?
>
> If I generate a stub using this WSDL as is, I only get the ability to
> perform:
> MessageElement[] messageElements = result.get_any();
>
> And not the specific getters for user name, user language etc etc that
> should appear in the response.
>
> I'm clearly missing something here, your thoughts and help would be
> appreciated.
>
>
> Dean.
>
>
>
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to