wsdl2java — generates JAX-WS compliant Java code from a WSDL document
<plugin> <groupId>org.apache.cxf</groupId> <artifactId>cxf-codegen-plugin</artifactId> <version>version</version> <executions> <execution> <id>generate-sources</id> <configuration> <defaultOptions><option>...</option>... </defaultOptions> <wsdlOptions> <wsdlOption> <wsdl>wsdlPath</wsdl><option>...</option>... </wsdlOption> ... </wsdlOptions> </configuration> <goals> <goal>wsdl2java</goal> </goals> </execution> </executions> </plugin>
The wsdl2java task takes a WSDL document and generates fully annotated Java code from which to implement a
service. The WSDL document must have a valid portType element, but it does not need to contain a
binding element or a service element. Using the optional arguments you can
customize the generated code.
At least one wsdlOptions element is required to configure the plug-in. The
wsdlOptions element's wsdl child is required and specifies a WSDL document
to be processed by the plug-in. In addition to the wsdl element, the
wsdlOptions element can take a number of children that can customize how the WSDL document is
processed.
![]() | Tip |
|---|---|
More than one |
For a complete list of the options for this task see wsdl2java.
The defaultOptions element is an optional element. It can be used to set options that are used
across all of the specified WSDL documents.
![]() | Important |
|---|---|
If an option is duplicated in the |
For a complete list of the options for this task see wsdl2java.