Re: question on the RDF(a) API...

On May 9, 2011, at 14:09 , Niklas Lindström wrote:

> Hi Ivan!
> 
> This is a good question. I think that the API should have a method of
> getting a Projection of your homepage directly from the Projection of
> you. This could be done by having get and getAll return Projections
> for objects that are references (i.e. either a uri or a bnode). That
> could make sense as these are "native" objects representing resources.
> 
> Either that or adding relRel/getRels for this purpose.

I would rather go for the second alternative. An automatism might become harmful if, say, I really want to get to that URI. But yes, I can see the value of having that thing separately.

Ivan


> I outlined a
> suggestion for this (with some reasoning) here:
> 
>    <http://lists.w3.org/Archives/Public/public-rdfa-wg/2011Apr/0062.html>
> 
> There I also mention getRev/retRevs for getting things referencing the
> subject of the current projection. And the problem of losing language
> information for resources, and a suggestion for dealing with that.
> 
> Best regards,
> Niklas
> 
> 
> 
> On Mon, May 9, 2011 at 1:20 PM, Ivan Herman <ivan@w3.org> wrote:
>> Guys,
>> 
>> for my understanding and possible editorial comment...
>> 
>> Say that I have a project collecting my foaf data. So I can say
>> 
>> name  = ivan.get("http://xmlns.com/foaf/0.1/name");
>> 
>> and this should return "Ivan Herman".
>> 
>> However, if I say
>> 
>> homepage = ivan.get("http://xmlns.com/foaf/0.1/homepage");
>> 
>> do I get the 'homepage' as a string, ie, the string "http://www.ivan-herman.net/"? In other words, is it so that the Projection interface essentially merges (or rather 'hides') the concepts of literals and uris?
>> 
>> Also, what happens if there is a blank node as an object? Eg.
>> 
>> <me> a foaf:Person ;
>>   foaf:knows [
>>        foaf:name "Manu Sporny";
>>   ] .
>> 
>> and then:
>> 
>> ivan = data.getProjection("<me>") ;
>> b = ivan.get("foaf:knows") ;
>> 
>> What is in "b"?
>> 
>> Ivan
>> 
>> ----
>> Ivan Herman, W3C Semantic Web Activity Lead
>> Home: http://www.w3.org/People/Ivan/
>> mobile: +31-641044153
>> PGP Key: http://www.ivan-herman.net/pgpkey.html
>> FOAF: http://www.ivan-herman.net/foaf.rdf
>> 
>> 
>> 
>> 
>> 
>> 
>> 


----
Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
mobile: +31-641044153
PGP Key: http://www.ivan-herman.net/pgpkey.html
FOAF: http://www.ivan-herman.net/foaf.rdf

Received on Monday, 9 May 2011 12:38:17 UTC