Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Creating an Apache Ant build file > Building the client

Building the client

Next, we demonstrate the new -clientjar option in wsimport to generate a JAR file for the web service portable artifacts and WSDLs to be made available to the JAX-WS runtime when the web service is invoked from a client. In the generate-client target, run the wsimport task and specify the JAR file to package the generated artifacts and WSDLs using the clientjar attribute. Specify the WSDL URL as http://localhost:8080/clientjar/hellows?wsdl with the wsdl attribute. In the wsdl URL, clientjar is the WAR file name for the deployed web service and hellows is the servlet pattern to invoke the web service servlet as specified in web.xml. As the JAR file is to be made available to the client at runtime, specify the package name the same as the package for the client class:


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial