- Created by user-b5542, last modified by Annegret Bernhardt on Dec 29, 2022
You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 2 Next »
In the Service panel resides a folder API where you can define your own service APIs.
Go to the API folder in the service panel of your service. | |
First you need to create the API needed for your service inside the API folder. All other elements will be created within this API. Add a new API via the quick action or the context menu. Refer to API for more information on how to create a new API in the API folder. Expert Advice Apply the same naming conventions to all your models. This makes reading a model much easier. Refer to Naming Conventions and Containment Tree Organization in the Builder User Guide for an overview on practice-approved naming conventions. |
API Elements
To define a service API, you have the following elements available:
Element | Description | Details | |||||
---|---|---|---|---|---|---|---|
API | An API is the entrance port of your service. It can be used to communicate with the service from the outside. There are different kinds of APIs (e.g. REST API, SOAP API, ...) that describe different communication standards. | ||||||
Port | Ports are elements of the UML modeling standard. A port defines an entrance point to the service and connects the API to an interface or class. | ||||||
Class | A class is an aggregation of properties and operations that describes a complex data type from which objects can be created. | ||||||
| Class | Classes can have sub-classes. | |||||
Operation | An operation adds behavior to a class or interface. The behavior describes how to process the data given by the parameters. In the context of the Designer, you can implement operations as mapping, action script or activity. | ||||||
| Parameter |
In contrast to a class, an interface has no properties nor implementations. Interfaces are used to define common operations of multiple classes, and then derive from that interface. | |||||
Interface |
In contrast to a class, an interface has no properties nor implementations. Interfaces are used to define common operations of multiple classes, and then derive from that interface. | ||||||
Interface | Interfaces can have sub-interfaces and sub-classes. | ||||||
Class | |||||||
Operation | Operations and parameters for interfaces are the same as for classes. The difference is that they have no implementation but only define the signature for the dependent classes to derive from. | ||||||
| Parameter |
Each element of the API folder has a context menu and quick actions. The context menu contains options to create new elements to the selected element, and to edit the current element. Via the quick actions, you can access the most used menu items directly with a single click.
API
An API is the entrance port of your service. It can be used to communicate with the service from the outside. There are different kinds of APIs (e.g. REST API, SOAP API, ...) that describe different communication standards.
The quick action of an API allows for the creation of ports.
| |||||||||||||||
The context menu of an API allows you to create a port, to cut, copy and paste the API, to change the name of the API, and to delete it.
|
Port
Ports are elements of the UML modeling standard. A port defines an entrance point to the service and connects the API to an interface or class.
The context menu of a port allows for the creation of classes and interfaces, to change the name of the port, and to delete it.
|
Class
A class is an aggregation of properties and operations that describes a complex data type from which objects can be created.
The quick actions of a class allow for the creation of operations with different types of implementation.
| |||||||||||||||||||
The context menu of a class allows you to create further elements, to cut, copy and paste the class, to change the name of the class, and to delete it.
|
Operation
An operation adds behavior to a class or interface. The behavior describes how to process the data given by the parameters. In the context of the Designer, you can implement operations as mapping, action script or activity.
The quick actions of an operation allow for the creation of parameters with different directions, and to jump to the implementation of the operation.
| |||||||||||
The context menu of an operation allows you to create further elements, to select and change the type of implementation of the operation and to open the implementation of the operation. Furthermore you can cut, copy and paste the operation, change the name of the operation, and delete it via this menu. |
Menu Item | Description |
---|---|
Add Parameter in | Add an input parameter to the operation. |
Add Parameter out | Add an output parameter to the operation. |
Add Parameter return | Add a return parameter to the operation. |
Add Operation (Suboperation) | Add a suboperation to the operation. |
Open (Implementation) | Open the implementation of the selected operation in a separate tab. Available if the operation has an implementation, yet. |
Change (Implementation) | Change the type of implementation or remove the implementation. Available if the operation has an implementation, yet. |
Create (Implementation) | You can choose between three different types of implementation for your class operations:
Available if the operation has no implementation, yet. |
Cut | Cut the operation to paste it elsewhere to the API or Implementation folder. |
Copy | Copy the operation to paste it elsewhere to the API or Implementation folder. |
Paste | Paste the operation elsewhere to the API or Implementation folder. Available if Copy or Cut option have been used before. |
Rename | Change the name of the operation. |
Delete | Delete the operation. |
Parameter
Operations can have parameters that define the input and output objects. Operation parameters can be of simple type (Base Types) or of complex type (class or interface).
The context menu of a parameter allows you to change the order of parameters as well as to change the names of a parameter. Furthermore you can cut, copy and paste a parameter. It is not possible to create further elements below a parameter.
|
If you want to change the direction of a parameter, select the parameter and change attribute Direction in the Attributes panel:
Interface
In contrast to a class, an interface has no properties nor implementations. Interfaces are used to define common operations of multiple classes, and then derive from that interface.
Operations of interfaces do not have an implementation but only define the signature (parameters and types).
The quick action of an interface allows for the creation of operations.
| |||||
The Interface context menu allows you to create further elements and to change the name of the interface. Furthermore you can cut, copy and paste as well as delete the interface via this menu. |
Menu Item | Description |
---|---|
Add Class | Add a class or sub-class to the interface. Classes within interfaces can be nested. |
Add Interface | Add another interface to the interface. Interfaces can be nested. |
Add Operation | Add an operation to the interface. Operations of interfaces do not have an implementation but only define the signature (parameters and types). |
Cut | Cut the interface to paste it elsewhere to the API or Implementation folder. |
Copy | Copy the interface to paste it elsewhere to the API or Implementation folder. |
Paste | Paste the interface elsewhere to the API or Implementation folder. Available if Copy or Cut option have been used before. |
Rename | Change the name of the interface. |
Delete | Delete the interface. |
RESTAPI_SupportManager_Example
- No labels