- From: Roger L. Costello <costello@mitre.org>
- Date: Wed, 19 Feb 2003 15:55:15 -0500
- To: www-rdf-interest@w3.org, "Costello,Roger L." <costello@mitre.org>
Hi Folks,
I have a couple of questions on RDF Schemas:
1. Suppose that I have an RDF/XML instance that contains a Length
property:
<Length>
<rdf:Description>
<rdf:value>6300</rdf:value>
<uom:units>kilometers</uom:units>
</rdf:Description>
</Length>
As you can see, the contents of Length is an anonymous resource.
How should Length be defined in an RDF Schema? Here is how I imagine
that it should be defined:
<rdf:Property rdf:ID="Length">
<rdfs:domain rdfs:resource="#River"/>
</rdf:Property>
Note that I do not specify an rdfs:range value, thus Length can have any
value. Is this the proper way to define a property with a value that is
an anonymous resource?
Similarly, above it shows a property uom:units within the anonymous
resource. I am not sure how to define it. I believe that this is how
to define it:
<rdf:Property rdf:ID="units">
<rdfs:range rdf:resource="http://.../rdf-schema#Literal"/>
</rdf:Property>
Note that I do not specify an rdfs:domain value, thus units can be used
in any class. Is this the proper way to define a property that is to be
used in an anonymous resource?
2. Consider this property definition of FlowRate:
<rdf:Property rdf:ID="FlowRate">
<rdfs:range rdf:resource="http://.../rdf-schema#Literal"/>
<rdfs:domain rdf:resource="#River"/>
<rdfs:domain rdf:resource="#Brook"/>
</rdf:Property>
Note the two rdfs:domain statements. This says that the property
FlowRate may be used with a class that is a River AND a Brook.
How do I define FlowRate so that it may be used with either a River
class OR a Brook class?
Is this the way to do it:
<rdf:Property rdf:ID="FlowRate">
<rdfs:range rdf:resource="http://.../rdf-schema#Literal"/>
</rdf:Property>
<rdf:Property rdf:about="#FlowRate">
<rdfs:domain rdf:resource="#River"/>
</rdf:Property>
<rdf:Property rdf:about="#FlowRate">
<rdfs:domain rdf:resource="#Brook"/>
</rdf:Property>
Note that I defined the FlowRate property first and then I "added to it"
using two more property definitions. Is this how ORing is achieved?
/Roger
Received on Wednesday, 19 February 2003 15:55:27 UTC