开发者

Chang PreFix for Ontology

开发者 https://www.devze.com 2023-02-03 04:47 出处:网络
I use protege 4 to merge 2 ontology sucessful and save as Onab.owl. In this file, I don\'t know how to change URI of ontology by OWL API. Could you help me use OWL API to change it

I use protege 4 to merge 2 ontology sucessful and save as Onab.owl. In this file, I don't know how to change URI of ontology by OWL API. Could you help me use OWL API to change it Thank you very muc开发者_开发问答h.


You can get and set the prefix name using methods of the org.semanticweb.owlapi.util.DefaultPrefixManager class. Good luck!


Create a SetOntologyID instance with the new IRI you want and apply it to the ontology:

manager.applyChange(ontology, setOntologyID());

Then save the ontology, its IRI will have been changed.

0

精彩评论

暂无评论...
验证码 换一张
取 消