version 2003
SET WEB SERVICE PARAMETER (name; value{; soapType})
Parameter | Type | Description | |
name | String | Name of parameter to include in SOAP request | |
value | Variable | 4D variable containing the value of the parameter | |
soapType | String | SOAP type of the parameter |
Description
The SET WEB SERVICE PARAMETER command enables the definition of a parameter used for a client SOAP request. Call this command for each parameter in the request (the number of times the command is called depends on the number of parameters).
In name, pass the name of the parameter as it must appear in the SOAP request.
In value, pass the 4D variable containing the value of the parameter. In the case of proxy methods, this variable is generally $1, $2, $3, etc., corresponding to a 4D parameter passed to the proxy method when it was called. It is, however, possible to use intermediary variables.
Note: Each 4D variable or array used must first be declared using the commands of the "Compiler" and "Arrays" themes.
By default, 4th Dimension automatically determines the most appropriate SOAP type for the name parameter according to the content of value. The indication of the type is included in the request.
However, you may want to "force" the definition of the SOAP type of a parameter. In this case, you can pass the optional soapType parameter using one of the following character strings (primary data types):
soapType | Description |
string | String |
int | Longint |
boolean | Boolean |
float | 32-bit real |
decimal | Real with decimal |
double | 64-bit real |
duration | Duration in years, months, days, hours, minutes, seconds, for example |
P1Y2M3DT10H30M | |
datetime | Date and time in ISO8601 format, for example 2003-05-31T13:20:00 |
time | Time, for example 13:20:00 |
date | Date, for example 2003-05-31 |
gyearmonth | Year and month (Gregorian calender), for example 2003-05 |
gyear | Year (Gregorian calender), for example 2003 |
gmonthday | Month and day (Gregorian calender), for example --05-31 |
gday | Day (Gregorian calender), for example ---31 |
gmonth | Month (Gregorian calender), for example --10-- |
hexbinary | Value expressed in hexadecimal |
base64binary | BLOB |
anyuri | Uniform Resource Identifier (URI), for example |
http://www.company.com/page | |
qname | Qualified XML name (namespace and local part) |
notation | Notation attribute |
Note: For more information about XML data types, refer to the URL http://www.w3.org/TR/xmlschema-2/
Example
This example defines two parameters:
C_TEXT($1) C_TEXT($2) SET WEB SERVICE PARAMETER("city";$1) SET WEB SERVICE PARAMETER("country";$2)
See Also
CALL WEB SERVICE, GET WEB SERVICE RESULT.