OK, thanks for the confirmation. Is there any workaround?
I thought about splitting the definition into two parts, like
<complexType name="Filter">
<choice>
<element name="and" type="tns:AndFilter"/>
<element name="or" type="tns:OrFilter"/>
<element name="not" type="tns:NotFilter"/>
</choice>
</complexType><complexType name="FilterList">
<sequence minOccurs="0" maxOccurs="unbounded>
<complexType ref="tns:Filter"/>
</sequence>
</complexType>... but I can't get that to work either. I think it's not proper XML schema.
Gilles Devaux wrote:
Same thing here, it appears that AXIS interpret the <xs:choice> element just like the <xs:sequence> element.
-----Message d'origine-----
De : Bill Keese [mailto:[EMAIL PROTECTED] Envoy� : mardi 22 f�vrier 2005 09:43
� : Axis-User
Objet : xsd:choice (and WSDL2Java)
It looks like WSDL2Java doesn't support xsd:choice for Axis 1.2. Can anyone confirm/deny this?
I had a declaration like this: <complexType name="FilterList"> <sequence minOccurs="1" maxOccurs="unbounded"> <choice> <element name="and" type="query:AndFilter"/> <element name="or" type="query:OrFilter"/> <element name="not" type="query:NotFilter"/> </choice> </sequence> </complexType>
I expected the generated java code to look like this: class FilterList { Filters[] filters; }
But instead it's a strange class like below. The problem w/the class below is that you can't have a FilterList containing two or more "and" nodes.
public class FilterList implements java.io.Serializable { private jp.co.beacon_it.inicio.client.soap.schema.query.AndFilter and; private jp.co.beacon_it.inicio.client.soap.schema.query.OrFilter or; private jp.co.beacon_it.inicio.client.soap.schema.query.NotFilter not; ... }
