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 "DELZANT Bruno (BMB)" <Br...@proximus.net> on 2009/01/16 15:48:40 UTC

Axis2: ADB code generation fails in particular case

Hi,
 
I ahve already posted once for this problem but I did not receive any
response, so I try again axplaining the problem in another way.
 
In a WSDL I get from a external supplier, this one in place of defining
data structure (namely usage of complextype), he uses exhaustive listing
of parameters like a sequence.
And he uses that in the message part of the wsdl. 
Here an example:
<message name="ppm_createResponse">
    <part name="returnValue" type="xsd:int" />
    <part name="returnComment" type="xsd:string" />
    <part name="accounid" type="xsd:string" />
    <part name="identify" type="xsd:string" />
</message>

I would have prefer to get something like for example:
<complexType name="responseType">
    <sequence>
        <element name="returnValue" type="xsd:int" />
        <element name="returnComment" type="xsd:string" />
        <element name="accounid" type="xsd:string" />
        <element name="identify" type="xsd:string" />
    </sequence>
</complexType>

<message name="ppm_createResponse">
    <part name="response" type="responseType" />
</message>

This ensure the ordering of the different elements because the problem
is here, the external supplier returns me soap message with the ordering
expressed by the different "part" section of message.

So first returnValue, then returnComment and so on.

But ADB code generation does not respect this order, he has its own
interpretation of the ordering and it do in a different order (in the
Factory.parse() method).
So off course when I try to parse the answer received I get "Unexpected
element" errors :-(

I have attached the wsdl that cause the problem, if hany one has any
clues to solve this or have a workaroud it would really appreciate !
Currently I modify the generate code to match the order I get ... not a
long term solution :-(

Thanks,
Bruno



**** DISCLAIMER**** 
http://www.proximus.be/maildisclaimer