Creating Operations for a Web Service
Prerequisites
-
Web Services Input Listener Connector with a WSDL file which is stored at the module itself
-
Templates (optionally)
XML Schema file or WSD file with operations which are similar to those you want to create.
The WSD file must use the same binding style which you have defined when configuring the Web service.
Refer to Provided Service Tab.
Proceed as follows
-
In the Web Service Editor, display Provided service tab.
-
Add operations
Do one of the following:
-
Click the Add operation button.
-
Select the root element, open the context menu and select Add operation.
A dialog opens.
-
Enter an appropriate name for the operation.
-
Select the type of operation:
-
Request/Response: Elements for the input and the output of the operation are added.
-
Request: Only an element for the input is added.
-
-
Click OK to close the dialog.
The operation is displayed with the defined name and the selected input/output parameters below the root element.
-
-
-
Add message part
-
Binding style document/literal
When creating the operation, message parts have been added automatically for the input and output message.
You can adjust the message part type, if necessary.
-
Binding style RPC/encoded and RPC/literal
You need to define message parts for input and output messages.
Proceed as follows:
-
In the tree view, select the parameter, to which you want to add a message part.
-
Open the context menu and select Add message part. A dialog opens.
-
Enter the name and type.
-
Close the dialog. The message part is displayed below its corresponding parameter, for example:
-
-
-
Using a template (optionally)
For typifying parameters, you can use simple or complex data types from an existing Schema file by drag-and-drop. You can also take over operations from other WSDL files by drag’n’drop.
Click the Template button at the bottom of the editor. The template docking windows opens:
Insert more operations and message parts corresponding to the functionality the Web service provides.