Wouter Bolsterlee wrote:
> 2006-10-25 klockan 12:27 skrev Jamie McCracken:
>> Ross Burton wrote:
>>> On Wed, 2006-10-25 at 11:12 +0100, Jamie McCracken wrote:
>>>>>> With everything mapped 1:1 you can then use RDF query to search them
>>>>> Why would you need a 1:1 mapping to do a query?  A query for "contacts
>>>>> with an email of [EMAIL PROTECTED]" should be possible
>>>>> independent of the number of email addresses a contact can have.
>>>> we need the 1:1 mapping to get/set the values. Whatever we implement we 
>>>> must have a unique metadata name for a particular service in order to do 
>>>> that otherwise getting or setting a value would be impossible.
>>>>
>>>> One problem with metadata relationships is that some metadata like in 
>>>> the above case would only be searchable like Contact.JabberID as the 
>>>> actual storage would be in Contact.WorkJabberID or Contact.HomeJabberID 
>>>> so it might get confusing for developers if they try and get the value 
>>>> of Contact.JabberID which would be NULL.
>>> A real world, physical example:
>>>
>>> Name: Ross Burton
>>> Email address (personal): [EMAIL PROTECTED]
>>> Email address (personal): [EMAIL PROTECTED]
>>> Email address (work): [EMAIL PROTECTED]
>>>
>>> How would you store this in Tracker?  If we declare that Tracker Contact
>>> objects are *not* vCard clones I can handle dropping the personal/work
>>> annotations for now.
>> would suggest:
>>
>> Contact.HomeEmailAddress : [EMAIL PROTECTED];[EMAIL PROTECTED]
>> Contact.WorkEmailAddress : [EMAIL PROTECTED]
>>
>> note using semicolon as delimiter so contents would need to be escaped 
>> for the semicolon. I guess standardising on semicolon delimiters might 
>> be a good idea?
> 
> Looks pretty useless to me. Delimiters in database field?
> 
> The RDF way would be (triples):
> 
>   hasPersonalEmail --- rdfs:subPropertyOf ---> hasEmail
>   hasWorkEmail     --- rdfs:subPropertyOf ---> hasEmail
>   RossBurton       --- hasWorkEmail       ---> [EMAIL PROTECTED]
>   RossBurton       --- hasPersonalEmail   ---> [EMAIL PROTECTED]
>   RossBurton       --- hasPersonalEmail   ---> [EMAIL PROTECTED]
> 
> You would then be able to query on "hasEmail" and get all three addresses.
> 

okay that looks nice.

I will add some kind of triple store (ie use three tables instead of the 
current two tracker uses for metadata).

I dont have plans to turn tracker into a full semantic web thing but I 
do want to take advantage of this in the simplest way possible.

Thanks for showing me the "light" :)

-- 
Mr Jamie McCracken
http://jamiemcc.livejournal.com/

_______________________________________________
desktop-devel-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/desktop-devel-list

Reply via email to