我正在使用 owlapi 返回给定类的个人。在使用比萨本体测试代码时,它运行良好,但是当我在本体上测试它时,出现以下异常:
Exception in thread "main" java.lang.NoClassDefFoundError: dk/brics/automaton/BasicAutomata
at org.semanticweb.HermiT.datatypes.rdfplainliteral.RDFPlainLiteralPatternValueSpaceSubset.<clinit>(RDFPlainLiteralPatternValueSpaceSubset.java:49)
at org.semanticweb.HermiT.datatypes.rdfplainliteral.RDFPlainLiteralDatatypeHandler.registerPatternDatatype(RDFPlainLiteralDatatypeHandler.java:53)
at org.semanticweb.HermiT.datatypes.rdfplainliteral.RDFPlainLiteralDatatypeHandler.<clinit>(RDFPlainLiteralDatatypeHandler.java:45)
at org.semanticweb.HermiT.datatypes.DatatypeRegistry.<clinit>(DatatypeRegistry.java:44)
at org.semanticweb.HermiT.structural.OWLClausification$DataRangeConverter.visit(OWLClausification.java:744)
at org.semanticweb.owlapi.model.OWLDatatype.accept(OWLDatatype.java:141)
at org.semanticweb.HermiT.structural.OWLClausification$DataRangeConverter.convertDataRange(OWLClausification.java:730)
at org.semanticweb.HermiT.structural.OWLClausification$NormalizedAxiomClausifier.visit(OWLClausification.java:574)
at org.semanticweb.owlapi.model.OWLDataAllValuesFrom.accept(OWLDataAllValuesFrom.java:52)
at org.semanticweb.HermiT.structural.OWLClausification.clausify(OWLClausification.java:162)
at org.semanticweb.HermiT.structural.OWLClausification.preprocessAndClausify(OWLClausification.java:92)
at org.semanticweb.HermiT.Reasoner.loadOntology(Reasoner.java:210)
at org.semanticweb.HermiT.Reasoner.<init>(Reasoner.java:201)
at org.semanticweb.HermiT.Reasoner.<init>(Reasoner.java:175)
at org.semanticweb.HermiT.ReasonerFactory.createHermiTOWLReasoner(ReasonerFactory.java:51)
at org.semanticweb.HermiT.ReasonerFactory.createReasoner(ReasonerFactory.java:19)
at org.semanticweb.HermiT.ReasonerFactory.createReasoner(ReasonerFactory.java:15)
at Main.main(Main.java:40)
我注意到问题是由于我在本体中使用的数据属性造成的。(当我删除所有数据属性时,它可以工作,但是当我添加它们时,错误再次出现)
小怪兽爱吃肉
相关分类