Hello All,
I have ontology like this (generate using Protégé :-D):
<owl:Class rdf:about="#Documentation_Project">
<owl:equivalentClass>
<owl:Class>
<owl:intersectionOf rdf:parseType="Collection">
<rdf:Description rdf:about="#Project"/>
<owl:Restriction>
<owl:onProperty rdf:resource="#produces"/>
<owl:allValuesFrom rdf:resource="#Authoring"/>
</owl:Restriction>
</owl:intersectionOf>
</owl:Class>
</owl:equivalentClass>
<owl:disjointWith rdf:resource="#Implementation_Project"/>
</owl:Class>
I try to serialize it using RDF API PHP the result is below:
<owl:Class rdf:ID="Documentation_Project"/>
<owl:Class rdf:nodeID="bNode11"/>
<rdf:Description rdf:ID="Documentation_Project">
<owl:equivalentClass rdf:nodeID="bNode11"/>
</rdf:Description>
<rdf:Description rdf:nodeID="bNode11">
<owl:intersectionOf rdf:nodeID="bNode12"/>
</rdf:Description>
<owl:onProperty rdf:ID="produces"/>
<owl:allValuesFrom rdf:ID="Authoring"/>
<rdf:Description rdf:nodeID="">
<rdf:first rdf:resource="#produces"/>
<rdf:rest rdf:nodeID="bNode13"/>
</rdf:Description>
<rdf:Description rdf:nodeID="bNode13">
<rdf:first rdf:resource="#Authoring"/>
<rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
</rdf:Description>
<rdf:Description rdf:nodeID="bNode12">
<rdf:first rdf:resource="#Project"/>
<rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
</rdf:Description>
That ontology has restriction: Implementation_Project _=_ Project AND
produces ONLY Authoring
The Questions:
1. How to query the restriction above using Sparql?
I mean the query result return the collection of Implementation_Project
I try :
SELECT ?o ?x
WHERE {
<http://www.example.com/ontology/thesis.owl#Documentation_Project>
<http://www.w3.org/2002/07/owl#equivalentClass> ?o
?o
<http://www.w3.org/2002/07/owl#intersectionOf> (?x)
}";
I got the Project only. Where is produces, allValueFrom
and Authoring?
Could you help this?
Thank you.
Best regards,
Dwi
|