wsdl2xml — generates a WSDL document containing an XML binding based on a portType
element.
wsdl2xml
[[-?] | [-help] | [-h]] [-i port-type-name
] [-b binding-name
] [-e service-name
] [-p port-name
] [-a address
] [-d output-directory
] [-o output-file
] [-v] [[-verbose] | [-quiet]] {wsdlurl
}
wsdl2xml generates an XML binding from an existing WSDL document containing a portType
element.
The arguments used to manage WSDL file generation are reviewed in the following table.
Option | Interpretation |
---|---|
-? | Displays the online help for this utility. |
-help | |
-h | |
-i
| Specifies the portType element to use. |
-b
| Specifies the name of the generated XML binding. |
-e
| Specifies the value of the generated service element's name attribute. |
-p | Specifies the value of the generated port element's name attribute. To specify multiple port elements, separate the names by a space. |
-a
| Specifies the value used in the address element of the generated port element. |
-d
| Specifies the directory to place generated WSDL file. |
-o
| Specifies the name of the generated WSDL file. |
-v
| Displays the version number for the tool. |
-verbose
| Displays comments during the code generation process. |
-quiet
| Suppresses comments during the code generation process. |
wsdlurl
| The path and name of the existing WSDL file. |
The -i
and the port-type-name
wsdlurl
arguments are required. All other arguments are optional and may be listed in any order.
To execute this tool using Ant set the java task's classname property to org.apache.cxf.tools.misc.WSDLToXML
.
Example 4 shows the java task to execute this command.
Example 4. Generating a SOAP Binding From Ant
<java classname="org.apache.cxf.tools.misc.WSDLToXML" fork="true"> <arg value="-i"/> <arg value="greeter"/> ... <arg value="MyWSDL.wsdl"/> <classpath> <path refid="artix_java.classpath"/> </classpath> </java>