W3C home > Mailing lists > Public > public-rdfa-wg@w3.org > January 2011

PROPOSAL to close ISSUE-56: DataContext needs base for relative URI resolution

From: Manu Sporny <msporny@digitalbazaar.com>
Date: Sun, 02 Jan 2011 20:30:31 -0500
Message-ID: <4D2126B7.2050904@digitalbazaar.com>
To: RDFa WG <public-rdfa-wg@w3.org>
If there are no objections to this proposal in 7 days, we will close
ISSUE-56: DataContext needs base for relative URI resolution.

http://www.w3.org/2010/02/rdfa/track/issues/56

This issue concerned the lack of a base attribute or argument that could
be used to resolve relative URIs in the DataContext.

The DataContext has been moved to the RDF API and renamed to Profile.
The Profile interface now contains the base attribute:

http://www.w3.org/2010/02/rdfa/sources/rdf-api/#idl-def-Profile

This attribute is accessible through the following path in the RDF API:

rdf.base

and the following path in the RDFa API (with RDF API support):

document.data.rdf.base

The RDF API also allows the base to be set when:

 * Calling the createProfile() method on RDFEnvironment
 * Calling the parse() method on DataParser
 * Calling the process() method on DataParser

The RDFa API spec states that the base is the following value in the
general case:

"""
Unless otherwise specified, the document base is effectively the value
of <code>window.location.toString()</code>.
"""

It also states that the parse method may set the base to a new value at
parse-time:

"""
The document base is effectively the value of window.location.toString()
if a DOM Node is passed into the method, or the provided URI if a
DOMString is provided to the method.
"""

In general, the base is assumed to be the current window.location value
if operating in a DOM environment. The base can be set by setting
rdf.base. The base can be set when calling any parsing method.

The proposal is to adopt these set of rules and the current text in the
RDF API and RDFa API spec.

Please comment in 7 days from this post if you object to this proposal.
If there are no objections within 7 days, ISSUE-56 will be closed.

-- manu

-- 
Manu Sporny (skype: msporny, twitter: manusporny)
President/CEO - Digital Bazaar, Inc.
blog: Linked Data in JSON
http://digitalbazaar.com/2010/10/30/json-ld/
Received on Monday, 3 January 2011 01:31:02 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 27 April 2012 04:55:08 GMT