Hi
all,
How is the order
determined for elements in complexType section in a wsdl when using java2wsdl
tool? I'm asking because I seem to get different order for the same complexType
in different wsdls. I have two Java service classes both referring to class
ModifiableVO. I ran java2wsdl on the two services, here's the resulting sections
for ModifiableVO in two wsdl files:
File
1:
<complexType abstract="true" name="ModifiableVO">
<complexContent>
<extension base="tns2:CreatorVO">
<sequence>
<element name="logChange" type="xsd:boolean"/>
<element name="modifiedBy" nillable="true" type="soapenc:string"/>
<element name="modifiedDate" nillable="true" type="xsd:dateTime"/>
<element name="dirtyAttributes" nillable="true" type="impl:ArrayOf_soapenc_string"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexContent>
<extension base="tns2:CreatorVO">
<sequence>
<element name="logChange" type="xsd:boolean"/>
<element name="modifiedBy" nillable="true" type="soapenc:string"/>
<element name="modifiedDate" nillable="true" type="xsd:dateTime"/>
<element name="dirtyAttributes" nillable="true" type="impl:ArrayOf_soapenc_string"/>
</sequence>
</extension>
</complexContent>
</complexType>
File
2:
<complexType abstract="true" name="ModifiableVO">
<complexContent>
<extension base="tns2:CreatorVO">
<sequence>
<element name="modifiedBy" nillable="true" type="soapenc:string"/>
<element name="logChange" type="xsd:boolean"/>
<element name="modifiedDate" nillable="true" type="xsd:dateTime"/>
<element name="dirtyAttributes" nillable="true" type="impl:ArrayOf_soapenc_string"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexContent>
<extension base="tns2:CreatorVO">
<sequence>
<element name="modifiedBy" nillable="true" type="soapenc:string"/>
<element name="logChange" type="xsd:boolean"/>
<element name="modifiedDate" nillable="true" type="xsd:dateTime"/>
<element name="dirtyAttributes" nillable="true" type="impl:ArrayOf_soapenc_string"/>
</sequence>
</extension>
</complexContent>
</complexType>
Notice the order of
logChange and modifiedBy were switched in file 2. This is a problem for me
as I need to generate client stubs, but only keep one ModifiableVO client stub,
and this cause compiling error for classes generated from one of the wsdl files.
Is there a way to set fixed order when running java2wsdl?
Thanks,
Yong
