ConnectorRequestUrl method: IntBroker class
Syntax
ConnectorRequestUrl(URL)
Description
Use the ConnectorRequestUrl method to return the URL for a connector.
You must have already set the connector parameters before executing this command.
Parameters
| Parameter | Description |
|---|---|
|
URL |
Specify an absolute URL as a string. |
Returns
A string.
Example
/**
* Get XML Doc from URL
*
* @param String - Location
* @return XmlDoc - retrieved XmlDoc
**/
method getXmlDocumentFromURL
/+ &location as String +/
/+ Returns XmlDoc +/
Local XmlDoc &xmldoc;
Local string &xmlstr;
If Substring(LTrim(RTrim(Upper(&location))), 1, 4) = "HTTP" Then
&xmlstr = %IntBroker.ConnectorRequestUrl(&location);
Else
&xmlstr = %This.getXmlContentFromFile(&location);
End-If;
&xmldoc = CreateXmlDoc("");
If &xmldoc.ParseXmlString(&xmlstr) Then
Return &xmldoc;
End-If;
end-method;
Related Topics