Fredrik Henricsson
Usenet Archive
- Joined
- Mar 23, 2005
- Messages
- 3
- Reaction score
- 0
Hey, I'm building an ontology in Protégé and I want to transform parts of it (e.g. the instances) to HTML with XSL. When I was transforming another file with 'simple' XML-tags like <author> before, I got it working, but the OWL-file is formatted differently and I don't know how to access the elements. I'll post the .owl file below, but this is basically what I want to get from the file (the course name):
</Course>
Any kind of help is appreciated.
The OWL-file:
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="MasterAI.xsl"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns
wl="http://www.w3.org/2002/07/owl#" xmlns="http://www.owl-ontologies.com/unnamed.owl#" xml:base="http://www.owl-ontologies.com/unnamed.owl"> <owl:Ontology rdf:about=""/> <owl:Class rdf:ID="Programme"> <rdfs:subClassOf> <owl:Class rdf:ID="MasterAI"/> </rdfs:subClassOf> <owl:disjointWith> <owl:Class rdf:ID="University"/> </owl:disjointWith> <owl:disjointWith> <owl:Class rdf:ID="Course"/> </owl:disjointWith> <owl:equivalentClass> <owl:Class> <owl:intersectionOf rdf
arseType="Collection"> <owl:Restriction> <owl:allValuesFrom> <owl:Class rdf:about="#Course"/> </owl:allValuesFrom> <owl
nProperty> <owl:ObjectProperty rdf:ID="hasCourse"/> </owl
nProperty> </owl:Restriction> <owl:Restriction> <owl
nProperty> <owl:ObjectProperty rdf:about="#hasCourse"/> </owl
nProperty> <owl:someValuesFrom> <owl:Class rdf:about="#Course"/> </owl:someValuesFrom> </owl:Restriction> </owl:intersectionOf> </owl:Class> </owl:equivalentClass> </owl:Class> <owl:Class rdf:about="#Course"> <owl:disjointWith> <owl:Class rdf:about="#University"/> </owl:disjointWith> <rdfs:subClassOf rdf:resource="#MasterAI"/> <owl:disjointWith rdf:resource="#Programme"/> </owl:Class> <owl:Class rdf:about="#University"> <rdfs:subClassOf rdf:resource="#MasterAI"/> <owl:disjointWith rdf:resource="#Course"/> <owl:equivalentClass> <owl:Class> <owl:intersectionOf rdf
arseType="Collection"> <owl:Restriction> <owl
nProperty> <owl:ObjectProperty rdf:ID="hasProgramme"/> </owl
nProperty> <owl:allValuesFrom rdf:resource="#Programme"/> </owl:Restriction> <owl:Restriction> <owl:someValuesFrom rdf:resource="#Programme"/> <owl
nProperty> <owl:ObjectProperty rdf:about="#hasProgramme"/> </owl
nProperty> </owl:Restriction> </owl:intersectionOf> </owl:Class> </owl:equivalentClass> <owl:disjointWith rdf:resource="#Programme"/> </owl:Class> <owl:Class rdf:ID="ProgrammeAI"> <rdfs:subClassOf rdf:resource="#Programme"/> </owl:Class> <owl:ObjectProperty rdf:about="#hasProgramme"> <rdfs:domain rdf:resource="#University"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#InverseFunctionalProperty"/> <rdfs:range rdf:resource="#Programme"/> <owl:inverseOf> <owl:FunctionalProperty rdf:ID="isProgrammeOf"/> </owl:inverseOf> </owl:ObjectProperty> <owl:ObjectProperty rdf:about="#hasCourse"> <rdfs:range rdf:resource="#Course"/> <rdfs:domain rdf:resource="#Programme"/> <owl:inverseOf> <owl:ObjectProperty rdf:ID="isCourseOf"/> </owl:inverseOf> </owl:ObjectProperty> <owl:ObjectProperty rdf:about="#isCourseOf"> <rdfs:domain rdf:resource="#Course"/> <owl:inverseOf rdf:resource="#hasCourse"/> <rdfs:range rdf:resource="#Programme"/> </owl:ObjectProperty> <owl
atatypeProperty rdf:ID="CourseName"> <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/> <rdfs:domain rdf:resource="#Course"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#FunctionalProperty"/> </owl
atatypeProperty> <owl
atatypeProperty rdf:ID="CourseECTS"> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#FunctionalProperty"/> <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#float"/> <rdfs:domain rdf:resource="#Course"/> </owl
atatypeProperty> <owl:FunctionalProperty rdf:ID="ProgrammeName"> <rdfs:domain rdf:resource="#Programme"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#DatatypeProperty"/> <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/> </owl:FunctionalProperty> <owl:FunctionalProperty rdf:ID="UniversityName"> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#DatatypeProperty"/> <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/> <rdfs:domain rdf:resource="#University"/> </owl:FunctionalProperty> <owl:FunctionalProperty rdf:about="#isProgrammeOf"> <owl:inverseOf rdf:resource="#hasProgramme"/> <rdfs:range rdf:resource="#University"/> <rdfs:domain rdf:resource="#Programme"/> <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#ObjectProperty"/> </owl:FunctionalProperty>
</rdf:RDF>
....Advanced Knowledge Technology</CourseName>
</Course>
Any kind of help is appreciated.
The OWL-file:
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="MasterAI.xsl"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns
<isCourseOf>Advanced Knowledge Technology</CourseName>
<hasCourse rdf:resource="#AdvancedKnowledgeTechnology"/> <isProgrammeOf>Mens-Machine Communicatie en Artificial Intelligence</ProgrammeName>
<hasProgramme rdf:resource="#MensMachineCommunicatie"/> </University> </isProgrammeOf> </ProgrammeAI>Groningen(RuG)</UniversityName>
</Course>5.0</CourseECTS>
</rdf:RDF>