W3C home > Mailing lists > Public > xml-uri@w3.org > May 2000

Re: When are two URIs equivalent?

From: <keshlam@us.ibm.com>
Date: Tue, 23 May 2000 10:26:23 -0400
To: xml-uri@w3.org
Message-ID: <852568E8.004F4FC1.00@D51MTA03.pok.ibm.com>
Note that string equality works for URIs ... but (arguably) not for URI
References. It is argued that they should be compared after being converted
into absolute URIs.

The process for doing so is described in the RPC which describes URI
References; basically, it says that if the URI Reference is relative it
should be combined with the base URI in effect at that point, and that any
/. and /..  should be resovled (by removing /., and by removing /..
together with the last /-delimited section of the base URI).

Note that /. and /.. are only removed if the original reference was
relative. If it was absolute, the absolutizing code leaves them alone. Thus
"http://foo/bar/./baz/../murph" is left unchanged by this process; it is
_not_ considered the same URI as "http://foo/bar/murph" even after

Also note that character escapes are _not_ converted by this process.
"http://foo/%61" is left unchanged; it is _not_ considered the same URI as
"http://foo/a"  even after absolutizing.

Reminder: We have not yet agreed on whether Namespace Names are or aren't
URI References. The Namespace spec currently says they are URI Refs but
that they're compared as literal strings, which some folks feel is a
conflict. The question is which of the three portions of that statement
should be considered an error:

LITERAL: That they _are_ URI references, as opposed to being expressed in
reference syntax.
FORBID: That they are URI _references_ (which can be relative) as opposed
to URIs (which can't).
ABSOLUTIZE: That they are compared as literals.

Joe Kesselman  / IBM Research
Received on Tuesday, 23 May 2000 10:27:07 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:13:58 UTC