This document describes the class URI
of the
JScript API. It implements some auxiliary functions that are useful for
processing URIs.
This constructor has one parameter: the URI as a string.
var myURI = new URI("http://mypc.mycompany.com/tamino/myDB"); var myURI = new URI("mydoctype/head.xml");
Name | toString() |
---|---|
Result Type | String |
Example | |
Description | Returns the URI argument as a string. |
Name | isAbsolute() |
---|---|
Result Type | String |
Example | |
Description | Returns true if the URI argument is an absolute URI, i.e., it contains the name of a protocol, otherwise false. |
Name | rebase(URI) |
---|---|
Result Type | String |
Example | |
Description | Takes the URI and a base parameter URI and returns a rebased URI. This method conforms to the URI rebasing algorithm documented in IETF RFC 2396. |
Name | extractURI(elementNode,
attribute) |
---|---|
Result Type | String |
Example | |
Description | Extracts an absolute URI from the attribute
within the element node, taking the xml:base information into
account. The document xml:base is the URI.
|
Name | getXMLBase(elementNode) |
---|---|
Result Type | String |
Example | |
Description | Calculates the xml:base value for
this node in its document context. The document xml:base is the
URI.
|
Name | truncateAtHash() |
---|---|
Result Type | String |
Example | |
Description | Returns the URI argument truncated before the first occurrence of "#", if any. |