Quantcast
Channel: Apache Timeline
Viewing all articles
Browse latest Browse all 5648

Cardinality Restriction with onDataRange

$
0
0
Hi!

I have a doubt about Jena OWL2 support and the
method createCardinalityQRestriction.

What I'm building now is something like that:

ns:sample
a owl:Class ;
rdfs:subClassOf
[ a owl:Restriction ;
owl:cardinality "1"^^xsd:int ;
owl:onProperty ns:longitude
] ;

ns:longitude
a owl:DatatypeProperty ;
rdfs:range xsd:string .

What I'd like to do is to add a owl:onDataRange to the owl:Restriction and
come up with this:

ns:sample
a owl:Class ;
rdfs:subClassOf
[ a owl:Restriction ;
owl:cardinality "1"^^xsd:int ;
owl:onProperty ns:longitude
* owl:onDataRange xsd:string*
] ;

ns:longitude
a owl:DatatypeProperty ;
rdfs:range xsd:string .

Is it possible? As far as I read the docs, the method
createCardinalityQRestriction could me help with that, but when I try to
use it, the following exception is thrown:

Exception in thread "main" com.hp.hpl.jena.ontology.ProfileException:
Attempted to use language construct CARDINALITY_Q that is not supported in
the current language profile: OWL DL

Is this about Jena OWL2 support? (I think that owl:onDataRange is OWL2
vocabulary, right?)

I tried with other language profile but no success.

Is there any other way I could do that declaration?!

Thanks,

Rodrigo C. Antonialli
======================================
Rio Claro - SP - Brasil
LinkedIn: http://www.linkedin.com/in/rcantonialli
Contato: (19) 98136-2347
rcantonialli [ at ] gmail.com
Skype: rc_antonialli

Viewing all articles
Browse latest Browse all 5648

Trending Articles