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

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.

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

				regards,
					Ted Hardie

Received on Tuesday, 19 February 2002 19:05:40 UTC