+

Search Tips   |   Advanced Search

WSDL2Java command for JAX-RPC applications


Run the WSDL2Java command-line tool against the WSDL file to create Java APIs and deployment descriptor templates.

A WSDL file describes a Web service. The Java API for XML-based Remote Procedure Call (JAX-RPC) 1.1 spec defines a Java API mapping that interacts with the Web service. The Web Services for Java EE spec defines deployment descriptors that deploy a Web service in a Java EE environment. The WSDL2Java command is run against the WSDL file to create Java APIs and deployment descriptor templates according to these specifications.

Best practice: It is a best practice to use absolute namespaces within the WSDL or schema. By default, the WSDL2Java tool does not permit the use of relative namespaces. Relative namespaces have been deprecated by the XML Plenary Interest Group and the use of relative namespaces causes the XML Digital Signature to fail as required by the Canonical XML Version 1.0 specification. However, if we have an established WSDL or schema that relies on relative namespaces, under specific conditions we can use the allowRelativeNamespace property to disable the relative namespace restrictions in the WSDL2Java tool. For additional information, see the property description. bprac

We can convert any relative namespaces to absolute namespaces.

The following is an example of a relative namespace:

targetNamespace="MyRelNamespace"
. We can change the relative namespace in this example to an absolute namespace by adding the protocol and base URI information:

targetNamespace="http://www.sample.com/MyRelNamespace"
.

 

Command-line syntax

The command-line syntax is:

WSDL2Java [arguments] WSDL-URI

 

Required arguments

 

Important arguments

 

Other arguments





Related concepts


Custom data binders for JAX-RPC applications
Assembly tools

 

Related tasks


Develop a service endpoint interface from Java Beans for JAX-RPC applications

 

Related


Java 2WSDL command for JAX-RPC applications
Mapping between Java language, WSDL and XML for JAX-RPC applications
Web services specifications and APIs