doPostEx
Executes an HTTP request using the POST method specifying the data stream and having the MIME type set automatically.
Format 1
void doPostEx( strUrl, content ) |
Format 2
void doPostEx( strUrl, type, content ) |
Format 3
void doPostEx( strUrl, type, content, hasDummyRoot ) |
Syntax rules
1. strUrl is the URL to invoke.
2. content contains the data stream.
3. type is the MIME type (i.e. "text/xml")
4. hasDummyRoot is an alphanumeric data item or literal hosting a boolean value (e.g. "0", "1", "true", "false", "yes", "no", "on" or "off"). If the boolean value is TRUE, then the top level item of Record-Definition is discarded and will not appear in the JSON stream . This parameter can be NULL, in such case, FALSE is assumed.
General rules
1. In Format 1,
type is set to "application/json" or "application/xml" depending on the Content-type request header field. If no Content-type field is available in the request header, then the type is controlled by the
iscobol.rest.default_stream configuration setting.
2. If content is an appropriately structured variable with external names and the type is set to "application/json", the method makes a request using the JSON format.
3. If content is an appropriately structured variable with external names but type is not set to "application/json", the method makes a request using the XML format.