You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Hoda Shums <ho...@bah.com> on 2006/07/27 00:28:23 UTC

Problem with wsdl2java

Hi,
 
I've ran into a seemingly simple problem that I can't find a solution
to. It seems that if you create a WSDL with request and response message
having the same element, axis's wsdl2java does not create java classes
reflecting that behavior. Here's an example:
 
<xsd:element name="XYZ" type="tns:XYZType"/>
<xsd:element name="XYZ2" type="tns:XYZType"/>
 
<wsdl:message name="getXYZResponse">
    <wsdl:part name="body" element="tns:XYZ"></wsdl:part>
</wsdl:message>
<wsdl:message name="getXYZRequest">
    <wsdl:part name="body" element="tns:XYZ"></wsdl:part>
</wsdl:message>

<wsdl:portType name="XYZPort">
    <wsdl:operation name="getXYZ">
        <wsdl:input message="tns:getXYZRequest"/>
        <wsdl:output message="tns:getXYZResponse"/>
    </wsdl:operation>
</wsdl:portType>

If I use this example in my WSDL, then the getXYZ method's return type
is void in the generated java class. But, if I replace either the
request or response's element with XYZ2, then the code generated is
perfectly fine. I need to have the soap request and response messages
looking the same, so that is not a viable option. Is there a work
around? I'm using Axis 1.4.
 
Thanks

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org