Mercurial > repos > mikel-egana-aranguren > oppl
diff OPPL/src/GalaxyOWLAPI.java @ 18:d3616fac4ca5 draft
Elk support added
author | Mikel Egana Aranguren <mikel-egana-aranguren@toolshed.g2.bx.psu.edu> |
---|---|
date | Thu, 20 Sep 2012 12:46:36 +0200 |
parents | c9e01f86b07c |
children |
line wrap: on
line diff
--- a/OPPL/src/GalaxyOWLAPI.java Mon Aug 20 11:39:56 2012 +0200 +++ b/OPPL/src/GalaxyOWLAPI.java Thu Sep 20 12:46:36 2012 +0200 @@ -12,10 +12,13 @@ import java.util.Scanner; import java.util.Set; +import org.apache.log4j.Level; +import org.apache.log4j.Logger; import org.coode.owlapi.manchesterowlsyntax.ManchesterOWLSyntaxEditorParser; import org.coode.owlapi.obo.parser.OBOOntologyFormat; import org.coode.parsers.BidirectionalShortFormProviderAdapter; import org.semanticweb.HermiT.Reasoner; +import org.semanticweb.elk.owlapi.ElkReasonerFactory; import org.semanticweb.owlapi.apibinding.OWLManager; import org.semanticweb.owlapi.expression.OWLEntityChecker; import org.semanticweb.owlapi.expression.ParserException; @@ -110,6 +113,14 @@ reasonerFactory = new Reasoner.ReasonerFactory(); reasoner = reasonerFactory.createReasoner(ontology); } + public void setReasonerElk (){ + reasonerFactory = new ElkReasonerFactory(); + Logger.getLogger("org.semanticweb.elk").setLevel(Level.OFF); + reasoner = reasonerFactory.createReasoner(ontology); + } + public void disposeReasoner(){ + reasoner.dispose(); + } public void merge (String ontologyIRI) throws OWLOntologyCreationException, OWLOntologyStorageException{ OWLOntologyMerger merger = new OWLOntologyMerger(manager); // OWLOntologyMerger merger = new OWLOntologyMerger(new OWLOntologyImportsClosureSetProvider(manager, ontology));