Re: OWL 2 Datatype Restrictions

Hi

Nathan wrote:
>>From what I can tell using xsd:pattern seems the correct approach,
> however wondering if anybody is already doing this / can somebody point
> me to an example in the wild or a snippet from an ontology that is
> already using xsd:pattern w/ DatatypeRestriction.

I'm using it in my OWL 2 version of the CIDOC Conceptual Reference Model [1].
In Turtle syntax I defined two datatypes as follows:

crm:EntityNotation a rdfs:Datatype ;
	owl:equivalentClass
		[
			a rdfs:Datatype ;
			owl:onDatatype xsd:string ;
			owl:withRestrictions ([xsd:pattern "E[1-9][0-9]*"])
		] ;
	rdfs:isDefinedBy <> .

crm:PropertyNotation a rdfs:Datatype ;
	owl:equivalentClass
		[
			a rdfs:Datatype ;
			owl:onDatatype xsd:string ;
			owl:withRestrictions ([xsd:pattern "P[1-9][0-9]*"])
		] ;
	rdfs:isDefinedBy <> .

Regards,
  Simon


[1] http://bloody-byte.net/rdf/cidoc-crm/

Received on Thursday, 21 January 2010 22:11:15 UTC