SOAP Web Services / Writing a Web Services server application |
Genero Web Services 2.0 allows you to create Web Services operations in the following styles:
Web Services Style | Description |
---|---|
RPC Style Service (RPC/Literal) | Generally used to execute a function, such as a service that returns a stock option. |
Document Style Service (Doc/Literal) | Generally used for more sophisticated operations that exchange complex data structures, such as a service that sends an invoice to an application, or exchanges a Word document; this is the MS.Net default. Both RPC/Literal and Doc/Literal Styles are WS-I compliant ( Web Services Interoperability organization). |
RPC Style Service (RPC/Encoded) | Provided only for backwards compatibility with older versions of web services already published. Important: This style is deprecated by the WS-I organization,
and is not recommended, as most Web Service implementations won't
support it in the future.
|
The style of service to be created is specified in the Genero application for the Web Service, using the following methods of the WebOperation class from from the Web Services COM Library (com). The parameters are the same for both methods:
LET op = com.WebOperation.CreateRPCStyle("add","Add", add_in,add_out) LET op = com.WebOperation.CreateDOCStyle("checkInvoice", "CheckInvoice",invoice_in,invoice_out)
Calling the appropriate function for the desired style is the only difference in your Genero code that creates the service. The remainder of the code that describes the service is the same, regardless of whether you want to create an RPC or Document style of service.
CALL serv.createHeader(var,FALSE)