From: Matthew H. <mat...@cs...> - 2008-03-18 18:56:45
|
Hi Amit, > Hi Matthew, > > On Tue, Mar 18, 2008 at 01:07:20PM +0000, Matthew Horridge wrote: >> Officially, there shouldn't be any declaration axioms in this >> ontology. Declaration axioms are only introduced with the >> owl11:declaredAs triple. For example, A owl11:declaredAs owl:Class. >> There is some contention about this at the moment. I expect the >> issue >> will be resolved before OWL 1.1 is fully standardised. > > Fair enough. My second question is how would I know that ClassA > has been > defined in the loaded ontology (without using OWL 1.1)? If I just > have > > <owl:Class rdf:ID="ClassA"/> > > I will essentially have no axioms returned? With the version of the API on SVN, by default, a declaration axiom will be created in this case. When you save the ontology, the declaration will not be saved as a declaredAs triple, but will be saved back as a type triple. Cheers, Matthew > regards >> >> Cheers, >> >> Matthew >> >> >> On 14 Mar 2008, at 17:04, Amit Kapoor wrote: >> >>> Hi folks, >>> >>> A bit of confusion on my part. The following is a rough code >>> snippet >>> (groovy) that I am running on an owl file: >>> >>> // Create our ontology manager in the usual way. >>> OWLOntologyManager manager = OWLManager.createOWLOntologyManager() >>> >>> // Load the ontologies >>> OWLOntology ont1 = >>> manager.loadOntologyFromPhysicalURI(URI.create(ont1_url)) >>> >>> println("\n\nPrinting various axioms in first ontology: ") >>> Set<OWLAxiom> axioms = ont1.getAxioms() >>> for (OWLAxiom axiom : axioms) { >>> println("Ontology axiom: " + axiom) >>> } >>> >>> Gives me a quick way to look at created axioms. I am running the >>> above code >>> against an owl file containing the following: >>> >>> <!-- Class definitions --> >>> <owl:Class rdf:ID="ClassA"/> >>> >>> <!-- Object properties --> >>> <owl:ObjectProperty rdf:about="&common;hasName"> >>> <rdfs:range rdf:resource="#ClassA"/> >>> </owl:ObjectProperty> >>> >>> <!-- Datatype Properties --> >>> <owl:DatatypeProperty rdf:about="&common;hasColour"> >>> <rdfs:range rdf:resource="&xsd;string"/> >>> </owl:DatatypeProperty> >>> >>> >>> >>> Here is what I am seeing being output running against code in >>> 'trunk' (svn >>> revision 636): >>> >>> >>> Printing various axioms in first ontology: >>> Ontology axiom: DataPropertyRange(hasColour string) >>> Ontology axiom: ObjectPropertyRange(hasName ClassA) >>> >>> >>> But if run the same code against an older version of OWLAPI >>> (packaged with >>> pellet) I see: >>> >>> >>> Printing various axioms in first ontology: >>> Ontology axiom: DataPropertyRange(hasColour string) >>> Ontology axiom: ObjectPropertyRange(hasName ClassA) >>> Ontology axiom: Declaration(hasColour) >>> >>> >>> Shouldn't I be seeing an axiom declaration for 'ClassA' and also >>> why is >>> declaration axiom missing for hasColour from code in 'trunk' >>> compared to >>> earlier revision? >>> >>> regards >>> >>> Amit >>> >>> ------------------------------------------------------------------------- >>> This SF.net email is sponsored by: Microsoft >>> Defy all challenges. Microsoft(R) Visual Studio 2008. >>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ >>> _______________________________________________ >>> Owlapi-developer mailing list >>> Owl...@li... >>> https://lists.sourceforge.net/lists/listinfo/owlapi-developer >> >> >> ------------------------------------------------------------------------- >> This SF.net email is sponsored by: Microsoft >> Defy all challenges. Microsoft(R) Visual Studio 2008. >> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ >> _______________________________________________ >> Owlapi-developer mailing list >> Owl...@li... >> https://lists.sourceforge.net/lists/listinfo/owlapi-developer > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer |