当我这样做时,它不起作用
OWLClassExpression query = factory.getOWLObjectIntersectionOf(factory.getOWLClass("#belgique", pm))
reasoner.getInstances(query,true);
这个正在工作:
reasoner.getInstances(factory.getOWLClass("#belgique", pm),true);
但问题是我需要 objectintersectionof 因为我需要属于几种类型的类的实例
我什至试过这个:
OWLClass newName = factory.getOWLClass(IRI.create("temp001"));
OWLAxiom definition = factory.getOWLEquivalentClassesAxiom(newName, query);
manager.addAxiom(ontology, definition);
reasoner.getInstances(newName,true)
它仍然无法正常工作