use of edu.stanford.bmir.protege.web.shared.obo.OBOTermSynonymScope in project webprotege by protegeproject.
the class TermSynonymsManager method getSynonyms.
public Collection<OBOTermSynonym> getSynonyms(OWLEntity term) {
Set<OBOTermSynonym> result = new HashSet<>();
for (OWLOntology ontology : rootOntology.getImportsClosure()) {
Set<OWLAnnotationAssertionAxiom> annotationAssertionAxioms = ontology.getAnnotationAssertionAxioms(term.getIRI());
for (OWLAnnotationAssertionAxiom ax : annotationAssertionAxioms) {
OBOTermSynonymScope synonymScope = getSynonymScope(ax);
if (synonymScope != null) {
OBOTermSynonym termSynonym = new OBOTermSynonym(xRefExtractor.getXRefs(ax), getStringValue(ax), synonymScope);
result.add(termSynonym);
}
}
}
return result;
}
Aggregations