I have an embedded axis2 service in my web application. When I try to create a wsdl it creates soemthing like
<xs:complexType name="AdminState">
<xs:complexContent>
<xs:extension base="xs:Enum">
<xs:sequence/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
But using this I am unable to create the client code. Eclipse complains about the following error
src-resolve.4.2: Error resolving component 'xs:Enum'. It was detected that 'xs:Enum' is in namespace 'http://www.w3.org/2001/XMLSchema', but components from this namespace are not referenceable from schema document 'file:///...xyz.wsdl'. If this is the incorrect namespace, perhaps the prefix of 'xs:Enum' needs to be changed. If this is the correct namespace, then an appropriate 'import' tag should be added to 'file:///..xyz.wsdl'.
Does Axis2 support enums?
I don't think it does
https://issues.apache.org/jira/browse/AXIS2-3967
I've been waiting on a fix as well
EDIT (07/18/2012): Seems like Axis2 1.7.0 now has support for enums. Time to test this out
Axis2 existing released versions does not support Enum parameters, java level or wsdl level.
But I would like to say that present trunk (1.7.0) of Axis2 supports JDK5 Enum in java level as well as wsdl level.
You can find my blog post Introducing Enum support with Apache Axis2 that explains how to use Enum support with Axis2 and how we can write a wsdl file which support Enum.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With