W3C home > Mailing lists > Public > public-rdf-in-xhtml-tf@w3.org > July 2007

Re: A Proposal for subject setting by @class

From: Ben Adida <ben@adida.net>
Date: Mon, 09 Jul 2007 08:32:50 -0700
Message-ID: <46925522.2060006@adida.net>
To: Ivan Herman <ivan@w3.org>
CC: RDFa <public-rdf-in-xhtml-tf@w3.org>


Ivan,

Yes, you got it right as to what the syntax does, though the reason you
provide is much more advanced than what I had in mind.

There is one big reason that drove this proposal. If you have the
following markup:

  <div class="cal:Vevent">
    ... stuff ...
  </div>

then I can't find a reasonable way to justify why "stuff" should be
about the current document: it's obviously about the event. Of course,
it would be *better* if the author added a @rel to explain what the heck
this free-floating event is on the page, but that doesn't mean we should
have an unintuitive default behavior.

This precise situation is going to arise when folks want to convert
microformats to RDFa to add a few fields. The first thing they will want
to do is convert

   class="hFoo"

to

   class="myvocab:Foo"

and then they've got the syntax I mention above, which should
intuitively cause contained markup be about this free-floating myvocab:Foo.

That's the reasoning, now feel free to tear it apart :)

-Ben

Ivan Herman wrote:
> Ben,
> 
> I need some clarification, to understand exactly what you propose.
> 
> At the moment, if I have in RDFa:
> 
> <div about="#me" id="me">
> 	<div the_attribute_that_shall_not_be_named="cal:Vevent"
> 	  rel="foaf:topic">
> 	  <span property="cal:dtstart">2007-07-07</span>
> 	</div>
> </div>
> 
> The generated RDF is, if I am not mistaken:
> 
> <#me> rel="foaf:topic" [
> 	a cal:Vevent;
> 	cal:dtstart "2007-07-07".
> 	].
> 
> which seems to cover the calendar event case that you refer to: I have a
> calendar event without naming it. However, regardless of the use case
> you refer to, I guess what you propose is that
> 
> <div about="#me" id="me">
> 	<div the_attribute_that_shall_not_be_named="cal:Vevent">
> 	  <span property="cal:dtstart">2007-07-07</span>
> 	</div>
> </div>
> 
> yields:
> 
> [
> 	a cal:Event;
> 	cal:dtstart "2007-07-07".
> ].
> 
> Is this correct? I presume the possible usage for this is:
> 
> <div about="#me" id="me">
> 	<div the_attribute_that_shall_not_be_named="cal:Vevent">
> 	  <span property="cal:dtstart">2007-07-07</span>
> 	  <span resource="a:Something" rev="a:something">Bla bla bla</span>
> 	</div>
> </div>
> 
> yielding:
> 
> <a:Something> a:something
> 	[
> 		a cal:Event;
> 		cal:dtstart "2007-07-07".
> 	].
> 	
> 
> Before I say yay or nay, I would like to understand whether this is what
> you refer to...
> 
> Thanks
> 
> Ivan
> 
> Ps: I realise I should have used
> "@resource_or_href_depending_on_decision" instead of "@resource" in the
> last example:-)
> 
> 
> Ben Adida wrote:
>> We've recently had a discussion about what to do when one wants to
>> publish a calendar event on a page without necessarily naming it.
>>
>> The recommendation was:
>>
>> <div class="cal:Vevent" rel="rdf:li">
>> ...
>>
>> or rel="foaf:topic"
>>
>> (note that I'm using the @class notation though this issue has now been
>> reopened, so assume
>>
>> the_attribute_that_shall_not_be_named="cal:Vevent"
>>
>> where I say @class.)
>>
>> I propose that, when a @class appears with a namespaced-value, there be
>> an implicit @about set for contained statements, exactly as if there
>> were a @rel. I suspect someone else has brought this up before, but I
>> can't seem to find it in the archive.
>>
>> So, for example:
>>
>> <div class="cal:Vevent">
>>   <span property="cal:dtstart">2007-07-07</span>
>> </div>
>>
>> would yield:
>>
>> _:div0 rdf:type cal:Vevent ;
>>        cal:dtstart "2007-07-07" .
>>
>> This is a small but noticeable change, and it may invalidate some
>> existing markup (though unlikely, since most use case here involve using
>> an @about on the same @div, in which case the @about takes precedence.)
>>
>> Thoughts, comments?
>>
>> -Ben
>>
> 
Received on Monday, 9 July 2007 15:33:02 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:15:08 GMT