Re: Abstract Classes

From: "Eric Jain" <Eric.Jain@isb-sib.ch>
Subject: Re: Abstract Classes
Date: Thu, 12 Feb 2004 16:53:04 +0100

> 
> > Maybe  you could explain what you are actually trying
> > to accomplish here
> 
> Given the following class hierarchy:
> 
>   <owl:Class rdf:ID="Feature"/>
> 
>   <owl:Class rdf:ID="Secondary_Structure_Feature">
>     <rdfs:subClassOf>
>       <owl:Class rdf:about="#Feature"/>
>     </rdfs:subClassOf>
>   </owl:Class>
> 
>   <owl:Class rdf:ID="Active_Site_Feature">
>     <rdfs:subClassOf>
>       <owl:Class rdf:about="#Feature"/>
>     </rdfs:subClassOf>
>   </owl:Class>
> 
> I would like to state that there are no instances that are Features but
> not also instances of a subclass of a Feature, ever. In OOP this can be
> accomplished simply by declaring the base class abstract. Quite possible
> that I'm too much caught up in the OOP mindset to see why such a
> restriction doesn't make sense from a logical point of view.

Well, in some sense you don't have to say ANYTHING for this to be true.
For example, any instance of the (named) class Feature is also an instance
of the (unnamed) class 

	<owl:Class>
          <owl:intersectionOf rdf:parseType="Collection">
	    <owl:Class rdf:about="#Feature" />
	    <owl:Class rdf:about="#Feature" />
	  </owl:intersectionOf>
	</owl:Class>

Perhaps you would like to say something stronger, perhaps that ``there are
no instances that are Features but not also instances of a proper subclass
of a Feature, ever''.  However, this doesn't work, as any instance of
Feature, say  

	<Feature rdf:about="#instance" />

is an instance of the class

	<owl:Class>
	    <owl:oneOf rdf:parseType="Collection">
	      <owl:Thing rdf:about="#instance" />
	    </owl:oneOf>
	</owl:Class>

which is a proper subclass of Feature.

Given that neither of these makes sense, just what is it that you want to
say?  Note that if you know that any Feature must be in one of a known set
of classes, C1 to Cn, you can say

	<owl:Class rdf:about="#Feature">
	  <rdfs:subClassOf>
	    <owl:Class>
	      <owl:unionOf rdf:parseType="Collection">
	        <owl:Class rdf:about="#C1" />
		...
		<owl:Class rdf:about="#Cn" />
	      </owl:unionOf>
	    </owl:Class>
	  </rdfs:subClassOf>
	</owl:Class>

However, you can't say in OWL that any particular instance of Feature has
to be known to be in one of the C1 to Cn.

Peter F. Patel-Schneider

Received on Thursday, 12 February 2004 11:17:01 UTC