- From: Dave Beckett <dave.beckett@bristol.ac.uk>
- Date: Wed, 14 Nov 2001 11:46:05 +0000
- To: Autumn Cuellar <a.cuellar@auckland.ac.nz>
- cc: www-rdf-comments@w3.org
I'm replying as the Editor of the
Refactoring RDF/XML Syntax W3C WD, 6 Sep 2001
http://www.w3.org/TR/2001/WD-rdf-syntax-grammar-20010906/
to which you refer.
>>>Autumn Cuellar said:
> We're using RDF to reference papers that we are describing in
> an XML-based language in hopes of one day creating an easily searchable
> database of biological models. One of the biggest appeals of using RDF
> was the ability to
> present an ordered sequence with the use of containers. We use this
> primarily in author listings because, as any published scientist will
> tell you, the order in which the authors are listed *does* matter.
>
> My understanding is that part of the reason the containers production
> was removed was that parsers should not be expected to recognize that
> the <li> elements indicated an order (i.e. <_1>, <_2>, and so on). But
> in Sect. 3.2 of the Sept. 6 Refactoring RDF/XML Syntax, there's the
> sentence "rdf:li elements will be translated to rdf:_nnn elements when
> they are found matching either a prpertElt or a typedNode." Is that
> sentence just meant to clear up any ambiguity that previously existed?
There was no ambiguity, but the rdf:li properties had a special place
in the grammar which stuck out as rather an un-necessary special
case. We merged the rdf:li handling into the handling of all other
properties, but had to describe the rdf:li -> rdf:_nnn rule in order
to generate the properties for containers in the same was as before.
So; this really is a refactoring of the grammar, not changing any way
of using rdf:li that previously was legal, but allowing it to be used
some new ways.
> So for an author listing, would the following indicate an ordered
> sequence? If not, is there currently a way to do so within RDF?
> <rdf:RDF
> xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
> xmlns:dc="http://purl.org/dc/elements/1.0/">
> <rdf:Description rdf:about="#some_article">
> <dc:creator>
> <rdf:li rdf:parseType="Resource">
> <name>Fred Flintstone</name>
> </rdf:li>
> <rdf:li rdf:parseType="Resource">
> <name>Barney Rubble</name>
> </rdf:li>
> <rdf:li rdf:parseType="Resource">
> <name>Dino</name>
> </rdf:li>
> </dc:creator>
> </rdf:Description>
> </rdf:RDF>
>
> Thanks in advance for clearing this up for me.
This is a (mostly) legal way to use rdf:li after the refactoring
document was published; since here you using rdf:li off a node which
is not of type rdf:Seq, rdf:Bag or rdf:Alt.
I say mostly legal since the <name> element has no declared
namespace. I assume that is a typo. You might want to try out the
RDF Validator at http://www.w3.org/RDF/Validator/ with your examples
which makes pretty graphs of the results.
Although this is allowed, If you wanted to say in a way that other
RDF applications can understand that these are a sequence, you will
have to use rdf:Seq inside the dc:creator property like this:
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:dc="http://purl.org/dc/elements/1.0/"
xmlns="http://example.org/">
<rdf:Description rdf:about="#some_article">
<dc:creator>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<name>Fred Flintstone</name>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<name>Barney Rubble</name>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<name>Dino</name>
</rdf:li>
</rdf:Seq>
</dc:creator>
</rdf:Description>
</rdf:RDF>
You might be interested in this document about modelling Dublin Core
in RDF/XML: http://dublincore.org/documents/2001/08/29/dcq-rdf-xml/
Note this is *not* an official RDF Core WG document.
I hope this answers your question.
Cheers
Dave
Received on Wednesday, 14 November 2001 06:46:12 UTC