New Web Service Client Wizard: Specify Web Service Client Information
See Also
The New Web Service Client wizard creates a new Web Service Client.
You open the New Web Service Client wizard by right-clicking a web application or
Java application, choosing New > File/Folder and selecting Web Service Client
from the Web Services category.
In the Specify Web Service Client Information page, you have to set the following properties:
- Specify the WSDL file of the web service:
- Project. Specifies an open project where the web service is defined. Click
Browse to locate it in the IDE.
- Local File. Specifies a WSDL file in your local filesystem. Click Browse
to locate it in your filesystem.
- WSDL URL. Specifies the URL to a running web service's WSDL file. If you
use a proxy server, you must click Proxy Settings and set the proxy host and port number,
otherwise the IDE will not be able to download the WSDL file.
- Package. Specifies the package where the client stubs and other artifacts will be generated.
Note that you will not be able to see this package and the client files in the Projects window, because they are
re-generated whenever you build the project and deleted when you clean the project. By default, files of this
nature are only displayed in the Files window and never in the Projects window. To override this behavior and display
the client files in the Projects window anyway, right-click the project node in the Projects window, choose Properties,
and use the Sources panel to add the package containing the client files. The package will then
be displayed in the Projects window, but beware of creating files in this package, because the
IDE will re-generate it when the project is built and delete it when the project is cleaned.
- Client Type. Specifies the type of client stubs that will be created by the wizard. The
types available depends on the web service architecure used:
- JAX-WS. (Java EE 5 specification) For consuming JAX-WS web services, there is one type
of web service client, the IDE-generated static stub. The IDE generates
the stub and other artifacts from the specified WSDL file, packages them in the archive,
and deploys them. Since
JAX-WS does not work with deployment descriptors, but uses annotations within
the Java code instead, a J2EE container-generated static stub, which
implies the use of deployment descriptors, would be superfluous.
- JAX-RPC. (J2EE 1.4 specification) For consuming JAX-RPC web services, there are two types of web service client:
- J2EE Container-generated static stub.
This type is based on JSR-109, which enhances JSR-101 by defining the packaging
of web services into standard J2EE modules, including a new deployment descriptor,
and defining web services that are implemented as session beans or servlets.
This is the recommended and portable (via J2EE 1.4 specification) type.
When you choose this type, the IDE adds deployment information in the
deployment descriptors and the container generates the stub and other artifacts.
- IDE-generated static stub.
This type is based on JSR-101, which defines the mapping of WSDL to Java and vice versa.
It also defines a client API to invoke a remote web service and a runtime environment
on the server to host a web service. This type is not portable.
When you choose this type, the IDE generates
the stub and other
artifacts, packages them in the archive, and deploys them.
- See Also
- About Web Services
Legal Notices