|
[OWLAPI-developer] [SWRL rules]
From: Daniel Maatary Okouya <okouya_d@ya...> - 2012-03-20 17:35
|
Dear all,
I seem to have an issue with swirl rules. I have a simple ontology with almost nothing in it, that is enough to test a rule.
I load my ontology, create the rule and then do some reasoning but i don't see it's result. However i can see that the rule is in memory with the following instruction:
OWLObjectRenderer renderer = new DLSyntaxObjectRenderer();
for (SWRLRule rule : ontology.getAxioms(AxiomType.SWRL_RULE)) {
System.out.println(renderer.render(rule));
}
So the rule axiom is there, but when i try to obtain the result of its application i get nothing.
however if i save the ontology (which now contain the rule). When re-execute the same code without this time re-receating the rule of course, my load rule from the file works perfectly.
Is it a normal behavior? That is, that every time you create an in-memory rule, you must first save it in a file and then reload it to be able to use it for reasoning ?
Many thanks,
Maatary
|