Generating Client-Side XML-Java Binding
To develop well-formed and valid requests from your client to the target Web service, you need to know the available methods of the Web service, the data types it uses, the interface to the service, the acceptable format of requests, the format of generated responses, etc. All this data is presented in the WSDL descriptor of the target Web service.
IntelliJ IDEA can generate the necessary client-side XML-Java bindings based on the desired WSDL descriptor, thus providing you with efficient coding assistance in developing client requests. You only need to specify the URL address of the WSDL descriptor, IntelliJ IDEA will retrieve the necessary data and generate Java classes.
Java code generation is configured in the Generate Java Code from Wsdl or Wadl dialog box, that primarily opens upon enabling the Web service client development support.
To configure generation of the client-side XML-Java binding
Open the Generate Java Code from Wsdl or Wadl dialog box by doing one of the following:
- Create a module and enable support of the Web Services client in it.
- At any time during the development, select the desired client module in the Project view and choose on the context menu.
- In the Web Service WSDL URL field, specify the URL address of the desired Web service WSDL descriptor.
- From the Output Path drop-down list, select the directory to place the generated files in.
- In the Package Prefix drop-down list, specify the package to place the compiled Java classes in.
- For the client side of an Apache Axis Web service, specify additional configuration options
for the code generation process using the following fields:
- Type Mapping Version
- Generate TestCase
- Generate Classes for Schema Arrays
- Generate Unreferenced Elements
- Support Wrapped Document/Literal Style