Re: problem of DAML+OIL

From: "Li Changqing" <lichangq@comp.nus.edu.sg>
Subject: problem of DAML+OIL
Date: Thu, 13 Mar 2003 18:28:21 +0800

> hi Sir/Mdm
> 
> I have two questions about the DAML+OIL:
> 
> in the animal ontology example specified by http://www.daml.org/2001/03/daml+oil-ex about the "daml:collection":
> 
>  <daml:Class rdf:about="#Person">
>    <rdfs:comment>every person is a man or a woman</rdfs:comment>
>    <daml:disjointUnionOf rdf:parseType="daml:collection">    
>      <daml:Class rdf:about="#Man"/>    
>      <daml:Class rdf:about="#Woman"/>
>    </daml:disjointUnionOf>
> </daml:Class>
> 
> The first question is:why did you use the "rdf:about" to refer to "#Man"
> and "#woman"; why didn't you use "rdf:resource" to refer to "#Man" and
> "#woman"? 

RDF/XML syntax is rather difficult to understand, as it uses many shorthand
notations.

Shorthand notations like

      <daml:Class rdf:about="#Man"/>    

are used when you have a member of a class (daml:Class in this case) and
want to refer to an instance of the class (#Man in this case).

Shorthand notations like

      <ex:friend rdf:resource="#Mary"/>    

are used when you want to specify a value (#Mary in this case) for a
property (ex:friend in this case).

> Can I use "rdf:resource" to refer to "#Man" and "#woman"? 

Here you can't because you need to provide an object (#Man), not a property
and its value.

> And the
> second question is:can I use "rdf:Seq" here instead of "daml:collection",
> since i want to union the the ordered members, such as the author of a
> book, but "daml:collection" is not with members ordered.

This would not work.  First, DAML+OIL (and also OWL) do not use rdf:Seq at
all, because of various problems with rdf:Seq and the other RDF container
vocabulary.  Second, union is inherently unordered so there is no reason to
use a construct that explicitly uses order.

> Thanks!
> Best regards
> 
> Changqing Li

Peter F. Patel-Schneider
Bell Labs Research
Lucent Technologies

Received on Thursday, 13 March 2003 06:47:15 UTC