W3C home > Mailing lists > Public > uri@w3.org > February 2002

Re: [Fwd: Re: [xml-dev] creating a URI class]

From: Dan Connolly <connolly@w3.org>
Date: 20 Feb 2002 00:31:55 -0600
To: hardie@oakthorn.com
Cc: "Simon St.Laurent" <simonstl@simonstl.com>, uri@w3.org, elharo@metalab.unc.edu, Mark Nottingham <mnot@mnot.net>
Message-Id: <1014186715.19852.125.camel@dirk>
On Tue, 2002-02-19 at 18:05, Ted Hardie wrote:
> Dan writes> 
> > URIs are character sequences; they're equal when they
> > have the same characters an unequal when they don't.
> > i.e. strcmp() is necessary and sufficient for comparing URIs.
> > 
> > There are cases when the URI spec guarantees that two URIs
> > point to the same thing; e.g.
> > 	http://www.w3.org/
> > and
> > 	http://WWW.W3.ORG/
> > 
> > but that doesn't make the two URIs equal. If you want
> > to be sure that consumers realize you mean the same thing,
> > I recommend writing it the same way, rather than relying
> > on consumers to do scheme-specific equivalence processing.
> 
> This seems to contradict to RFC 2396, sections 2.1 and 3.
> 3, in particular, says:
> 
>    The URI syntax does not require that the scheme-specific-part have
>    any general structure or set of semantics which is common among all
>    URI.  
> 
> I read that to mean that http://www.bar.org/ and http://www.BAR.org/
> may be equivalent where file://123abcdef and file://123ABCDEF might
> not be, and that a reference to the definition of the http and file
> URI schemes would be required to determine which semantics need be
> applied.

But that doesn't mean that http://www.bar.org/
and http://www.BAR.org/ are the same URI.

> In other words, the URI spec seems to say that semantic equivalence is
> scheme specific and string comparison alone is not enough.

string comparison is enough to tell if two URIs are the same
URI.


-- 
Dan Connolly, W3C http://www.w3.org/People/Connolly/
Received on Wednesday, 20 February 2002 01:31:25 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 13 January 2011 12:15:30 GMT