wood burning stoves 2.0*
The moose likes Web Services and the fly likes Ant & wsimport Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Ant & wsimport" Watch "Ant & wsimport" New topic
Author

Ant & wsimport

Fabio Saracino
Greenhorn

Joined: Nov 23, 2008
Posts: 5
Hello, I need to generate java artifacts from WSDL file using wsimport. I want to use wsimport by ant script, but I have some questions :

- where should I create the Ant scritp in the project (I use netbeans). Where should I put the following custom text :

<taskdef name="wsimport" classname="com.sun.tools.ws.ant.WsImport">
<classpath path="${java.home}/../lib/tools.jar:${j2ee.platform.wsimport.classpath}:${javac.classpath}"/>
</taskdef>

<wsimport
wsdl="..."
destdir="directory for generated class files"
sourcedestdir="directory for generated source files"
keep="true|false"
extension="true|false"
verbose="true|false"
wsdlLocation="..."
catalog="catalog file"
package="package name"
binding="..."
quiet="true|false"
xadditionalHeaders="true|false"
xauthfile="authorization file"
xdebug="true|false"
xNoAddressingDatabinding="true|false"
xnocompile="true|false"
<binding dir="..." includes="..." />
<arg value="..."/>
<xjcarg value="..."/>
<xmlcatalog refid="another catalog file"/>
</wsimport>

- can I launch Ant from code?

Thank you!
 
 
subject: Ant & wsimport