On 12/13/2011 01:51 PM, Stephen Bayliss wrote:
> In ECM, the type of an object is defined effectively from its CModel.
> One can validate the type of the target of a relationship, the typing
> being specified by the hasModel relationship.
> Is it possible to do any additional type validation; eg if I want to
> enforce that all objects "belonging" to the CModel must assert an
> rdf:type relationship?
Sure, specify the minCardinality for the rdf:type relation. That way,
all subscribing objects must have an rdf:type relationship.
> I've tried adding an owl:Restriction on the rdf:type relationship
> using owl:hasValue to specify the value of the target (rather than its
> class) - but this doesn't look as if it is implemented.
NOTE: the value constraint|owl:hasValue|is not included in OWL Lite.
> I've also tried using an owl:Restriction on a hasMember relationship;
> instead of specifying the target's CModel class I used a value that
> the target is itself asserting using rdf:type, but it doesn't lok like
> this is tested for.
rdf:type is a sore point for OWL. Fedora CMA does not concern itself
with rdf:type. A fedora object is NOT "of a type" just because it
subscribe to a content model.
Now, one could define
fedora:hasModel isSubtypeOf rdf:type
The problem here is that, to owl, fedora:hasModel is an
owl:ObjectProperty and rdf:type is a rdf:Property. To make the above
statement understandable to a reasoner, you would need owl full.
For the purpose of ECM, i defined that
object fedora:hasModel contentmodel creates a phony rdf property
object rdf:type contentmodel#class
This property is, of course, not added to the triple store.
Remember that it does require owl full, if a content model should be
both an object and a class. That is why we use contentmodel#class for
the rdf:type information.
> So a question, is ECM relationships validation restricted to:
> 1) checking the cardinality of a relationship
> 2) checking the type of the target of a relationship where the type is
> specified using hasModel
> Is there anything one can do for enforcing rdf:type assertions?
writing a schema for the RELS-EXT datastream?
<!-- Insert required element here...-->
But on a more serious note, no, there isn't. To do this right, we need
1. To define the implied relation between fedora:hasModel and rdf:type
2a. Find an apache-licensed reasoner, that support more than owl-lite
(or switch fedora to gpl3, and use pellet)
2b/ Or: choose to support some subset of owl full/DL specification, and
thus in effect, make our own dialect of owl.
> (Though I realise in practice, with reasoning support, one would make
> a statement about the CModel#class that it is eg a subtype, or
> owl:sameAs etc).