Chapter 8 Working with Web Services
You can create a Web service with the wizard that will guide you through the creation of the component. The wizard is invoked from a class diagram and is only available if you use the Java or the .NET family.
You can either create a Web service without selecting any class, or use the standard approach that consists in selecting an existing class first and then start the wizard from the contextual menu of the class.
You can also create several Web services of the same type by selecting several classes at the same time. The wizard will automatically create one Web service per class. The classes you have selected in the class diagram become Web service classes, they are renamed to match the naming conventions standard, and they are linked to the new Web service component.
Using a namespace
You must create the Web service component within a package so that the package acts as a namespace.
The wizard for creation of Web services lets you define the following parameters:
Property | Description |
---|---|
Name | Name of the Web service component |
Code | Code of the Web service component |
Web service type | Interface or Implementation. Interface refers to a component that defines the service interface only. Implementation refers to a component that implements a service interface |
Component type | The component type depends on the web service type. You can select among a list of web service interface or implementation protocols |
Web service implementation class | Defines the class that is used to implement the Web service |
Create symbol | Creates a component symbol in the diagram specified beside the Create symbol In check box. If a component diagram already exists, you can select one from the list. You can also display the diagram properties by selecting the Properties tool |
Create Class Diagram for component classifiers | Available only for stateless session beans and servlets. It creates a class diagram with a symbol for each class and interface. If you have selected classes and interfaces before starting the wizard, they are used to create the component. This option allows you to display these classes and interfaces in a diagram |
To create a Web service with the wizard:
Component type | Java service interface | Java service implementation | Use |
---|---|---|---|
Standard | — | Java class | |
Axis RPC | — | Java class | |
Axis EJB | — | EJB Stateless Session Bean | |
Java Web Service (JWS) | — | Java class with .jws extension | |
JAXM | — | Java Servlet | |
JAX-RPC | — | Java class | |
Web Service for J2EE | — | EJB Stateless Session Bean |
When you have finished using the wizard, the following actions are executed:
Copyright (C) 2006. Sybase Inc. All rights reserved. |