Clickatell SOAP wsdl to JAXB java classes
java, web-services
Solution
Your schema refers to the type `SOAP-ENC:Array` defined in the schema `xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/` but that schema is not included in the wsdl.
I had a similar problem and had to use a catalog to tell jaxb/xjc where to find the schema.
Go to http://schemas.xmlsoap.org/soap/encoding/ and save as soapenc.xsd
Then create a plain text file with following content
PUBLIC "http://schemas.xmlsoap.org/soap/encoding/" "soapenc.xsd"
Then pass that file to xjc as the catalog file
Update: If you are on maven, this is how it would all hang together.
place the schema, soapenc.xsd, and catalog.cat(the plain text file) in src/main/resources
Then tell the jaxb plugin to pass the catalog to xjc
<plugin>
<groupId>org.jvnet.jaxb2.maven2</groupId>
<artifactId>maven-jaxb2-plugin</artifactId>
<executions>
<execution>
<id>wsdl-generate</id>
<configuration>
<schemaIncludes>
<include>*.wsdl</include>
</schemaIncludes>
<catalog>${project.basedir}/src/main/resources/catalog.cat</catalog>
</configuration>
<goals>
<goal>generate</goal>
</goals>
</execution>
</executions>
</plugin>
Problem
I'm trying to generate JAXB classes from the Clickatell wsdl: You can find the wsdl definition here it quite large: http://api.clickatell.com/soap/webservice.php?WSDL When trying to generate java classes from this Wsdl i got the following errors: [ERROR] undefined simple or complex type 'SOAP-ENC:Array' [ERROR] undefined attribute 'SOAP-ENC:arrayType' I hope someone can help me out. Cheers, Tim