uCosminexus Application Server, Web Service Development Guide
This subsection describes the precautions on mapping from WSDL to Java.
When multiple operations are coded in 1 port type, all the operation names must be unique. Therefore, when mapping WSDL to Java, you cannot overload the Java methods. If the operation name is duplicated, customize the name and specify a unique name for each operation.
When the cjwsimport command is executed, a name conflict might occur in the SEI name, class name, method name, and parameter name. This point describes the mapping for name conflict.
When mapping WSDL to the Java source, if a name conflict occurs in the SEI name and class name (non-exception Java class name, exception class name, service class name, and skeleton class name), the name conflict is resolved according to the priority order.
The following table describes the priority order and solutions for a name conflict. No. indicates the priority order (No.1 is the highest).
Table 15-19 Priority order and solutions for name conflict
| No. | Types | Solutions for name conflict |
|---|---|---|
| 1 | SEI name | The priority order is highest, so the name is not changed. |
| 2 | Non-exception Java class name | Suffix _Type is added to the class name. |
| 3 | Exception class name | Suffix _Exception is added to the class name. |
| 4 | Service class name | Suffix _Service is added to the class name. |
| 5 | Skeleton class name | Suffix _Impl is added to the class name. |
The following figure shows an example of name resolution when a conflict occurs between the SEI name and the non-exception Java class name:
Figure 15-15 Name resolution when a conflict occurs between the SEI name and the non-exception Java class name
If a class name with the same name as the class name to which a suffix is added due to name resolution is defined, name conflict occurs again. In this case, the conflict is resolved by deleting the underscore from the defined class name.
The following figure shows an example of name resolution when a name conflict occurs after a suffix is added:
Figure 15-16 Example of name resolution when a name conflict occurs after a suffix is added
Moreover, if a class name with the same name as the class name that was changed by the deletion of the underscore is defined, an error message is output in the standard error output and log and the processing ends (KDJW51030-E#).
When mapping WSDL to the Java source, if a name conflict occurs in the methods and method parameters, the name conflict is not resolved and an error occurs.
The cjwsimport command supports Comformance 2.17 of the JAX-WS 2.2 specifications. When you execute the cjwsimport command, the following JAXB annotations are added to SEI as required:
Note that the MIME binding is not supported in the Cosminexus JAX-WS functionality, so the javax.xml.bind.annotation.XmlMimeType annotation is not added. If MIME binding is specified, an error message is output in the standard error output and log and the processing ends (KDJW51188-E).
All Rights Reserved. Copyright (C) 2013, Hitachi, Ltd.