Function | Package: net.uri | ToC | DocOverview | CGDoc | RelNotes | FAQ | Index | PermutedIndex
| Allegro CL version 9.0 Unrevised from 8.2 to 9.0. 8.2 version

## parse-uri

Arguments: string-or-uri &key (class (quote uri))

If string-or-uri is a uri instance, return it unmodified. If string-or-uri is a string, parse it into a URI object. Escaped encodings of the form %<hex><hex> are properly converted into single characters except the characters #\+, #\= and #\& are not decoded if they are percent encoded. This means %2b, for example, will not be converted to "+". This is contrary to RFC 3986, but otherwise there is no way to pass these characters as field values.

The class keyword allows creation of subclasses of `uri`.

If the result is a URN (that is, an object of class `urn`), urn-nid and urn-nss access the Namespace Identifier and the Namespace Specific String of the URN, while urn-q-component, urn-r-component, and urn-f-component access the q, r, and f components.

The operator string-to-uri also takes a URI and returns a string. Warning: parse-uri and render-uri are paired as are string-to-uri and uri-to-string. Users ahould never apply an operator from one pair to the return value of an operator from the other pair. The consequences of doing so are undefined.

See also uri.htm for general information on Universal Resource Indicator support in Allegro CL.

Copyright (c) 1998-2019, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 8.2 page.
Created 2012.5.30.

|  | ToC | DocOverview | CGDoc | RelNotes | FAQ | Index | PermutedIndex
| Allegro CL version 9.0 Unrevised from 8.2 to 9.0. 8.2 version