W3C home > Mailing lists > Public > public-rdfa-wg@w3.org > March 2010

Re: a 'loose' vocab proposal

From: Manu Sporny <msporny@digitalbazaar.com>
Date: Sun, 21 Mar 2010 13:44:45 -0400
Message-ID: <4BA65B0D.2030901@digitalbazaar.com>
To: RDFa WG <public-rdfa-wg@w3.org>
On 03/20/2010 05:50 PM, Martin McEvoy wrote:
> 1, Set the "default prefix"  by using the attribute "vocab"
> 
> <div vocab="http://www.w3.org/2006/vcard/ns#">
>     <div about="#fred" typeof="VCard">
>         <div property="fn">Fred</div>
>         <a rel="url" href="http://example.com/"> Home </a>
>     </div>
> </div>
>
> If a Parser encounters nested vocab's treat the first ( parent ) vocab
> as the "default prefix" . For all child vocab's generate  a pseudo
> prefix, example: ns1, ns2, ns3 ... etc , this will help avoid generating
> "invalid" RDF/XML  by switching  the default namespace mid parse.   (
> Ivans and my concern )

Could you elaborate what you mean by "pseudo prefix" and "switching the
default namespace mid parse"?

> 2. Extending vocabulary terms  using "vocab:"
> Shane McCarron  also mentioned in a message to the list that the vocab
> attribute  should be scoped just like xmlns (I hope I understood that
> correctly),

I don't think that's what Shane meant. I believe he meant that if @vocab
was specified like this:

<body>
   <div vocab="foo: xyz;">
   ...
   </div>

   <p>
   </p>
</body>

that the "foo" mapping wouldn't be in the list of mappings when the P
element is processed. He didn't mean "scoped as if declared by xmlns:
and used as a prefix for attribute names".

> <div vocab="http://www.w3.org/2006/vcard/ns#">
>     <div about="#fred"  typeof="VCard"
>          vocab:me="http://gmpg.org/xfn/11#me">
>         <div property="fn">Fred</div>
>         <a rel="url me" href="http://example.com/"> Home </a>
>     </div>
> </div>

We should think twice before going down this route for a number of reasons:

1. It would require us to make another xmlns-like proposal in the HTML
   WG - which is hostile to XML namespaces for a variety of good and
   not-so-good reasons. We would be creating a very long and disruptive
   discussion between WHATWG, HTML WG and RDFa WG if we were to pursue
   this.
2. It puts the onus on us to resolve the namespacing issues in HTML5 -
   which we're already doing for xmlns, but will have to now do for
   vocab: as well.
3. I don't see what this accomplishes that xmlns: + @vocab-as-the-
   default-prefix wouldn't accomplish. It seems like the same proposal
   as saying that @vocab defines the default prefix, xmlns: creates
   prefix mappings, and colon-less CURIEs are allowed.

-- manu

-- 
Manu Sporny (skype: msporny, twitter: manusporny)
President/CEO - Digital Bazaar, Inc.
blog: PaySwarming Goes Open Source
http://blog.digitalbazaar.com/2010/02/01/bitmunk-payswarming/
Received on Sunday, 21 March 2010 17:45:14 GMT

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