Hi, i try to use wsconsume with ant,
<target name="target" description="Generates classes"> <path id="wscon.classpath"> <path path="${project.classpath}"/> </path> <taskdef name="wsconsume" classname="org.jboss.ws.tools.jaxws.ant.wsconsume"> <classpath refid="wscon.classpath"/> </taskdef> <wsconsume fork="true" verbose="true" destdir="output" sourcedestdir="gen-src" keep="true" wsdl="http://api.tradera.com/v1/publicservice.asmx?WSDL"> </wsconsume> </target>
[wsconsume] Command invoked: org.jboss.ws.tools.jaxws.command.wsconsume -k -o C:\workspace\ipl_tradera\output -s C:\workspace\ipl_tradera\gen-src -t http://api.tradera.com/v1/publicservice.asmx?WSDL [wsconsume] Exception in thread "main" java.lang.NoClassDefFoundError: gnu/getopt/LongOpt [wsconsume] at org.jboss.ws.tools.jaxws.command.wsconsume.parseArguments(wsconsume.java:82) [wsconsume] at org.jboss.ws.tools.jaxws.command.wsconsume.main(wsconsume.java:75)
You need the getopt.jar in the classpath. If you are using Jboss 4.2 then that file is in the client directory under jboss home.
-Rahul