Hi, we have an ontology editor that stores ontologies and their terms in a triplestore. On the other end, they are being loaded by OntDocumentManager.
The question is: what is the proper way to clear and reload an ontology and its imports in OntDocumentManager? Because, for example, a user could totally change owl:imports statements of an ontology, and we need this feature to be able to reload a completely new OntModel without any old imported submodels. Right now I'm simply doing the following: OntDocumentManager.getInstance().getFileManager().removeCacheModel(ontologyURI) OntDocumentManager.getInstance().addModel(ontologyURI, infModel); OntModel ontModel = OntDocumentManager.getInstance().getOntology(ontologyURI, ontModelSpec); But this is not enough, because doing ontModel.listImportedOntologyURIs() lists all the old imports from before. Am I getting this right and what needs to be done to reload the imports as well? I can see there is a concept of dynamic imports in OntModel, but not sure it's related. Martynas