Skip to main content
Skip table of contents

parseUrl() Function

Syntax

aUrlObject = aUrlString.parseUrl()

Semantics

Parses an URL given in a String variable into the following data structure:

parseUrl() uses the following defaults:

  • If no scheme/protocol is given, https is supplied as default scheme.

  • If not given, the port is derived from the scheme/protocol, e.g. 443 for https.

Apart from these defaults: not given elements will be NULL in the data structure.

Substitutables

aUrlString

A String containing a valid URL.

parseUrl()does not decode any part of aUrlString. This must be taken care of by the modeler.

aUrlObject

An object of type URL.

Error Codes

Find the related error codes on System Errors.

FUMSM/32

URL parsing error.

Examples

Assume the following input URL string aUrlString: https://acme-corp.com/products

NONE
create aUrlobject;
set aUrlObject = aUrlString.parseUrl();

 This produces the following output:

CODE
{
  "scheme": "https",
  "host": "acme-corp.com",
  "port:" "443",
  "path": "products"
}
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.