The UML-to-WSDL transformation generates output in the target project or folder that is specified in the transformation configuration.
If the source model contains WSDL port types or XSD types, the transformation generates WSDL import statements in the transformation output. WSDL import statements import the namespaces of the WSDL Port Types and XSD types. You can only import namespaces that are in the existing workspace. The transformation does not modify WSDL port types and XSD types in the source model, nor does the transformation copy these resources to the target project or folder specified in the transformation configuration.
The transformation generates output based on the structure of the source model. In the output that the transformation generates, the namespaces of the WSDL elements and XSD schemas are based on the name of the UML element, or the name of the UML package or UML component.
If the component in the source model contains XSD schema elements, and the component is a service provider, the transformation generates the XSD schema inline, in the same WSDL file.
The following examples describe the structure of the transformation output, based on varying source model structures:
In this example, the UML elements that describe a Web service are contained in one component in the source model. A package called com.ibm.example1 contains a component called Component1. A class called Class1, which is in Component1, contains an attribute called id, and an attribute called name. An interface called Interface1, which is in Component1, contains an operation called Operation1. Operation1 contains a parameter called exception1, a parameter called parameter1, and a return parameter called result.

| Generated WSDL resource | WSDL property | Value |
|---|---|---|
| [Transformation target]\[Package name]\...\[parent Package name]\com.ibm.example1\Component1\Component1.wsdl | targetNamespace | http://[Package name]/../[parent Package name]/com.ibm.example1/Component1 |
In this example, the UML elements that describe a Web service are contained in the same package, but are not contained in a component that represents the Web service. A package called com.ibm.example2 contains a class called Class2, a component called Component2, and an interface called Interface2. The interface has an operation called Operation2, and Operation2 has a parameter called exception2, a parameter called parameter, and a return parameter called result.

| Generated WSDL resource | WSDL property | Value |
|---|---|---|
| [Transformation target]\com\ibm\example2\Component2.wsdl | targetNamespace | http://com.ibm.example2/Component2/ |
| [Transformation target]\com\ibm\example2\com_ibm_example2.wsdl | targetNamespace | http://com.ibm.example2/ |
In this example, the UML elements that describe a Web service are contained in different packages. A package called com.ibm.data3 contains a class called Class3, which has an attribute called id and an attribute called name. Another package, called com.ibm.example3, contains a component called Component3. A third package, called com.ibm.spec3, contains an interface called Interface3, that contains a parameter called exception3, a parameter called parameter3, and a return parameter called result.

| Generated WSDL resource | WSDL property | Value |
|---|---|---|
| [Transformation target]\com\ibm\example3\Component3.wsdl | targetNamespace | http://com.ibm.example3/Component3/ |
| [Transformation target]\com\ibm\spec3\com_ibm_spec3.wsdl | targetNamespace | http://com.ibm.spec3/wsdl/ |
| [Transformation target]\com\ibm\data3\com_ibm_data3.xsd | targetNamespace | http://com.ibm.data3/xsd/ |