String id = null; if (cv.hasNames()) { name = cv.getNames().getShortLabel();
private <T extends ControlledVocabulary> T findOrCreateControlledVocabulary(CvType cvType, Class<T> bpCvClass) { if (cvType == null) return null; // try full name first, else try short name String term = null; if (cvType.hasNames()) { term = getName(cvType.getNames()); } //xref and primaryRef must always exist, acc. to the schema UnificationXref bpXref = getPrimaryUnificationXref(cvType.getXref()); T toReturn = findOrCreateControlledVocabulary(term, bpXref, bpCvClass); return toReturn; }
if (interactorType != null && interactorType.hasNames()) { entityType = getName(interactorType.getNames());