Re: question on RDFa subject resolution

If I understand this correctly, I want to point out that the syntax
document [1] has an error in 6.2.

      <section id="person">
...
        <h1 property="foaf:name">Dan Brickley</h1>
      </section>

will not generate

<#person> foaf:name "Dan Brickley"^^rdf:XMLLiteral .

Instead, it will generate

<> foaf:name "Dan Brickley"^^rdf:XMLLiteral .

I will be including several tests in the test suite to make sure that the
id attribute behavior is properly tested.

Wing

Internet Technology
wingyung@us.ibm.com
617.693.3763


                                                                           
             Ben Adida                                                     
             <ben@adida.net>                                               
             Sent by:                                                   To 
             public-rdf-in-xht         bob@snee.com                        
             ml-tf-request@w3.                                          cc 
             org                       public-rdf-in-xhtml-tf@w3.org       
                                                                   Subject 
                                       Re: question on RDFa subject        
             02/09/2007 10:50          resolution                          
             AM                                                            
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           





Bob DuCharme wrote:
> When should it pick up an id attribute as a subject?

If I make a mistake here (and this is why we need to finish the Syntax
document ASAP), I hope Mark can come in and correct me :)

In the current specification, and ID attribute becomes the subject in
two specific cases:

1) the triple you're considering was generated by a LINK or META, and
there is an ID on the immediate parent.

2) you can encounter, as you go up the ancestor hierarchy and BEFORE you
hit an ABOUT, an element with a rel="", no href="", and an id="". This
case is *not yet* reflected in the RDFa Syntax document, and is meant to
handle the following striping situation:

========
This paper was written by
<div rel="dc:creator" id="me">
  <span property="foaf:name">Ben Adida</span>,
  <a rel="foaf:mbox" href="mailto:ben@adida.net">ben@adida.net</a>.
</div>
========

which yields:

========
<> dc:creator <#me> .

#me foaf:name "Ben Adida" ;
    foaf:mbox <mailto:ben@adida.net> .
========


Note how, in both of these cases, the absence of an ID would yield a
bnode. That's the way you can remember where ID comes in: if you would
otherwise get a bnode, but you actually want it addressable, you can use
ID. Note also how, in both cases, an ABOUT on the *same* element will
trump the ID.


-Ben

Received on Saturday, 10 February 2007 18:12:59 UTC