Apache | WS |
WebServices - AxisAxis-wsdl2java TaskCreate Java classes from local or remote WSDL. DescriptionCreate Java classes from local or remote WSDL. Mappings from namespaces to packages can be provided as nested <mapping> elements. Proxy settings are taken from the java runtime settings of http.ProxyHost, http.ProxyPort, etc. The Ant task <setProxy> can set these. As well as the nested mapping elements, this task uses the file NStoPkg.properties in the project base directory for namespace mapping This task does no dependency checking; files are generated whether they need to be or not. The exception to this is the Impl class, which is not overwritten if it exists. This is a safety measure. However, all other classes are generated overwriting anything that exists. The safe way to use this task is to have it generate the java source in a build directory, then have a <copy> task selectively copy the files you need into a safe location. Again, copying into the source tree is dangerous, but a separate build/src tree is safe. Then include this separate tree in the <javac> task's src attribute to include it in the build. Implement your own implementation classes of the server stub and the test cases using the generated templates. If you want to add methods to autogenerated data types, consider subclassing them, or write helper classes. Tip: if you <get> the wsdl, and use the <filesmatch> condition to compare the fetched wsdl with a catched copy, you can make the target that calls the axis-wsd2ljava task conditional on the WSDL having changed. This stops spurious code regeneration and follow-on rebuilds across the java source tree. Parameters
Parameters as nested elementsmapping (org.apache.axis.tools.ant.wsdl.NamespaceMapping) mappingset (org.apache.axis.tools.ant.wsdl.MappingSet) |