definition problem?: appending "#foo" without removing "#" from base URI

The RDF/XML Syntax Specification (Revised), in section 5.3, Resolving
URIs, says:

    ...XML Base...and RFC 2396...do not specify an algorithm for
    resolving a fragment identifier alone, such as #foo, ...into
    an RDF URI reference. In RDF/XML, a fragment identifier is
    transformed into a RDF URI reference by appending the fragment
    identifier to the in-scope base URI.

Does any fragment component in the base URI need to be removed before
appending the fragment identifier being resolved?


I can't quite tell if the base URI is already restricted to being a
"pure" URI (as opposed to a URI reference) or not.  (RFC 2396 mostly
implies that there is no fragment identifier, but also says "the...
fragment component[] [is]...not inherited from the base URI," which
implies that the base URI might have had a fragment component.))

If the base URI cannot contain any fragment identifier, then there is
no problem with the RDF/XML spec.

However, if the base URI can be a URI reference, then it might already
contain a fragment identifier.  Appending another fragment identifier
would yield an invalid URI reference (e.g., taking "http://h/path#" and
appending "#foo" would yield "http://h/path##foo").

If that second case is possible, then RDF/XML should specify that any
fragment component in the base URI be removed before appending the given
fragment identifier.



Daniel

Received on Monday, 12 January 2004 14:18:47 UTC