W3C home > Mailing lists > Public > www-rdf-interest@w3.org > January 2005

RSS 1.1 usage of parseType="Collection"

From: Ian Davis <iand@internetalchemy.org>
Date: Wed, 19 Jan 2005 14:55:27 +0000
Message-ID: <41EE74DF.6070801@internetalchemy.org>
To: www-rdf-interest@w3.org

I've been corresponding with Sean Palmer and Christopher Schmidt about 
the usage of an RDF List rather than one of the old container classes in 
their RSS 1.1 proposal. I think it has some semantic implications which 
may cause problems with aggregation and I'm looking for some other 
opinions on this.

Given an RSS 1.1 document with some items:

<Channel rdf:about="channel:URI">
    <items rdf:parseType="Collection">
       <Item><title>Post B</title></Item>
       <Item><title>Post A</title></Item>
    </items>
</Channel>

the triples produced are:

<channel:URI> :items _:b1 .
_:b1 rdf:first _:b2 .
_:b2 rdf:type :Item .
_:b2 :title "Post B" .
_:b2 rdf:rest _:b3 .
_:b3 rdf:type :Item .
_:b3 :title "Post A" .
_:b3 rdf:rest rdf:nil .

Later on, a subsequent fetch of the same channel has the following XML:

<Channel rdf:about="channel:URI">
    <items rdf:parseType="Collection">
       <Item><title>Post C</title></Item>
       <Item><title>Post B</title></Item>
    </items>
</Channel>

and the following triples

<channel:URI> :items _:b4 .
_:b4 rdf:first _:b5 .
_:b5 rdf:type :Item .
_:b5 :title "Post C" .
_:b5 rdf:rest _:b6 .
_:b6 rdf:type :Item .
_:b6 :title "Post B" .
_:b6 rdf:rest rdf:nil .

When merged you end up with:

<channel:URI> :items _:b1 .
_:b1 rdf:first _:b2 .
_:b2 rdf:type :Item .
_:b2 :title "Post B" .
_:b2 rdf:rest _:b3 .
_:b3 rdf:type :Item .
_:b3 :title "Post A" .
_:b3 rdf:rest rdf:nil .
<channel:URI> :items _:b4 .
_:b4 rdf:first _:b5 .
_:b5 rdf:type :Item .
_:b5 :title "Post C" .
_:b5 rdf:rest _:b6 .
_:b6 rdf:type :Item .
_:b6 :title "Post B" .
_:b6 rdf:rest rdf:nil .

First question: if an OWL schema for RSS 1.1 asserted that the 
cardinality of the items property was 1 then would an OWL reasoner 
conclude that _:b1 and _:b4 are the same and hence merge the triples to 
produce an ill-formed list?

Second question: an interpretation of collections is that they are 
exhaustive enumerations so that a reasoner can conclude that no other 
members exist. Is it, then, a contradiction to have different elements 
in the collection at different points in time?

Third question: how would one write a SPARQL query for the above 
construct. Assume I want to extract the channel title, and each item 
with its title and descripton from a smushed store containing data from 
multiple channels. With RSS 1.0 I can do the following:

PREFIX rss: <http://purl.org/rss/1.0/>
SELECT ?channeltitle ?title ?description
WHERE ( ?channel rdf:type rss:channel)
       ( ?channel rss:title ?channeltitle )
       ( ?channel rss:items ?items )
       ( ?items ?li ?item )
       ( ?item rss:title ?title )
       ( ?item rss:description ?description )

I'm not even sure where to start with RSS 1.1 - does anyone have a 
suggestion for me?


Cheers,

Ian
Received on Wednesday, 19 January 2005 14:55:31 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:52:12 GMT