I'm trying to reduce the complexity of the problem I'm having with the C code generator. I've reduced it to a simple example that demonstrates one of the problems I'm having (attached) when trying to generate client code.

The generated code below uses an undefined type "getFooBar" in the parameter list:

void axis2_stub_FooBarAdapterService_getFooBar_start( axis2_stub_t *stub, const axis2_env_t *env,
                                                        getFooBar param0,
axis2_status_t ( AXIS2_CALL *on_complete ) (struct axis2_callback *, const axis2_env_t* ) , axis2_status_t ( AXIS2_CALL *on_error ) (struct axis2_callback *, const axis2_env_t*, int ) );

my guess is that this should be an "axis2_getFooBarRequest" object instead of "getFooBar" for param0 (yes/no?) but there seems to be no .c or .h file generated that contains a request object. the generated files are:

axis2_FooBarObject.c
axis2_FooBarObject.h
axis2_getFooBar.c
axis2_getFooBar.h
axis2_getFooBarResponse.c
axis2_getFooBarResponse.h
axis2_stub_FooBarAdapterService.c
axis2_stub_FooBarAdapterService.h

Or, should the axis2_stub_FooBarAdapterService_getFooBar_start() function instead have a parameter list that reflects the "parameterOrder" attribute of the "wsdl:operation" tag in the WSDL file (ie: "string fooId" and "long barId")?

I'm using a build I made from a source snapshot yesterday (on WinXP with jdk1.5.0_10). the command I'm running to generate the code is:

wsdl2java.bat -l c -d adb -a -u -uri FooBar.wsdl

and with the following environment variable set JAVA_OPTS=-Dorg.apache.adb.properties=/org/apache/axis2/schema/c-schema-compile.properties

I've tried some different options, with no luck. I've also looked through Jira but so far haven't found anything that seems to match this problem--but maybe I'm using the wrong keywords.

Can someone tell me what's wrong with the wsdl, the wsdl2java command, or if this is a known issue? I'm willing to try to fix this if it is a bug, but I'm not sure where to start looking.

thanks!




<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="urn:foobar" xmlns:apachesoap="http://xml.apache.org/xml-soap"; xmlns:impl="urn:foobar" xmlns:intf="urn:foobar" xmlns:tns1="http://foo.bar.com"; xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"; xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
<!--WSDL created by Apache Axis version: 1.4
Built on Apr 22, 2006 (06:55:48 PDT)-->
 <wsdl:types>
  <schema targetNamespace="http://foo.bar.com"; xmlns="http://www.w3.org/2001/XMLSchema";>
   <import namespace="http://xml.apache.org/xml-soap"/>
   <import namespace="urn:foobar"/>
   <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
   <complexType name="FooBarObject">
    <sequence>
     <element name="fooId" nillable="true" type="xsd:string"/>
     <element name="barId" nillable="true" type="xsd:long"/>
    </sequence>
   </complexType>
  </schema>
 </wsdl:types>

   <wsdl:message name="getFooBarRequest">

      <wsdl:part name="fooId" type="xsd:string"/>
      <wsdl:part name="barId" type="xsd:long"/>

   </wsdl:message>

   <wsdl:message name="getFooBarResponse">

      <wsdl:part name="getFooBarReturn" type="tns1:FooBarObject"/>

   </wsdl:message>

   <wsdl:portType name="FooBarAxisAdapter">

      <wsdl:operation name="getFooBar" parameterOrder="fooId barId">

         <wsdl:input message="impl:getFooBarRequest" name="getFooBarRequest"/>

         <wsdl:output message="impl:getFooBarResponse" name="getFooBarResponse"/>

      </wsdl:operation>

   </wsdl:portType>

   <wsdl:binding name="FooBarSoapBinding" type="impl:FooBarAxisAdapter">

      <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>

      <wsdl:operation name="getFooBar">

         <wsdlsoap:operation soapAction=""/>

         <wsdl:input name="getFooBarRequest">

            <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; namespace="urn:foobar" use="encoded"/>

         </wsdl:input>

         <wsdl:output name="getFooBarResponse">

            <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; namespace="urn:foobar" use="encoded"/>

         </wsdl:output>

      </wsdl:operation>

   </wsdl:binding>

   <wsdl:service name="FooBarAdapterService">

  <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
blah blah blah
</wsdl:documentation>

      <wsdl:port binding="impl:FooBarSoapBinding" name="FooBar">

         <wsdlsoap:address location="http://127.0.0.1/metadata/services/FooBar"/>

      </wsdl:port>

   </wsdl:service>

</wsdl:definitions>

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

Reply via email to