|
VADELIA |
|
WADELIA |
EADELIA |
(I/B) (C) |
(I/B) (C) |
(B) (C) |
Context for use
SOAP Web Service consumption.
Section for use
All
Syntax
WS_GET_XMLRES WebServiceId OperationId QueryId DataRes
QueryId |
→ |
*ID(numId) | None |
numId |
→ |
VarNumId | CstNum |
DataRes |
→ |
SoaphdrRes | SoaphdrRes | SoapbodyRes SoaphdrRes |
SoapbodyRes |
→ |
*SOAPBODY_MEM(SoapbodyResMem) | *SOAPBODY_FILE(SoapbodyResFile) |
SoapbodyResMem |
→ |
VarRes | VarRes, Encoding |
SoapbodyResFile |
→ |
FileRes | FileRes, Encoding |
SoaphdrRes |
→ |
*SOAPHDR_MEM (SoaphdrMemRes) | * SOAPHDR_FILE(SoaphdrFileRes) |
SoaphdrMemRes |
→ |
MemRes | MemRes, Encoding |
SoaphdrFileRes |
→ |
FileRes | FileRes, Encoding |
MemRes |
→ |
AlphaVar | varImage |
FileRes |
→ |
AlphaVar | 'AlphaConstant' |
Encoding |
→ |
AlphaVar | 'AlphaConstant' |
Description
This instruction is used either to retrieve the SOAP message header, the body of the SOAP message, or both simultaneously.
The result is retrieved to an IMAGE variable, an ALPHA variable, or to an XML file. Target character encoding can be specified; by default UTF-8 encoding is used.
Notes:
- Instruction not supported for a SOAP 'RPC/Encoded' Web service called in "parameter" mode.
- The instruction can be called multiple times and is not exclusive with the WS_GET_VAL and WS_COUNT_VAL instructions.
Example
/* Retrieves the body of the result message to an ALPHA variable with 'windows-1252' encoding.
ALPHA(32000) SoapbodyRes
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPBODY_MEM(SoapbodyRes, 'windows-1252')
/* Retrieves the body of the result message to a file with 'UTF-8' encoding:
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPBODY_FILE('c:\resService\resBody.xml')
/* Retrieves the body of the result message to a file with 'windows-1252' encoding:
ALPHA(32) resficname
ALPHA(32) encoding
resficname = 'c:\resService\resBody.xml'
encoding = 'windows-1252'
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPBODY_FILE(resficname, encoding)
/* Retrieves the header of the result message to an ALPHA variable with 'windows-1252' encoding.
ALPHA(32000) resHdr
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPHDR_MEM(resHdr, 'windows-1252')
/* Retrieves the header of the result message to a file with 'UTF-8' encoding:
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPHDR_FILE('c:\resService\resHdr.xml')
/* Retrieves the header of the result message to a file with 'windows-1252' encoding:
ALPHA(32) resficname
ALPHA(32) encoding
resficname = 'c:\resService\resHdr.xml'
encoding = 'windows-1252'
WS_GET_XMLRES GLOBALWEATHER GetWeather *SOAPHDR_FILE(resficname, encoding)