Collection<Link> children = term.getChildren(); paths.put(trm.getChild().getID(), distance); logger.error("Stack overflow when computing child paths for: " + term.getID() + " for relationships: " + relationshipType); throw new IllegalStateException(e);
public Collection<IdentifiedObject> getRootOBOObjects( OboCategory... categories ) { ArrayList<IdentifiedObject> rootOboObjects = new ArrayList<IdentifiedObject>(); OBOObject rootObj = ( OBOObject ) oboSession.getObject( MI_ROOT_IDENTIFIER ); Collection<Link> childLinks = rootObj.getChildren(); for ( Link childLink : childLinks ) { if (MI_ROOT_IDENTIFIER.equals(childLink.getParent().getID())) { OBOObject immediateChildOfRoot = (OBOObject) childLink.getChild(); if ( checkIfCategorySubset( immediateChildOfRoot, categories ) ) { rootOboObjects.add( immediateChildOfRoot ); } } } log.debug( "oboObjects " + rootOboObjects.size() ); return rootOboObjects; }
final String parentId = parentLink.getParent().getID(); cvClass = findCvClassforMI(parentId);
Collection<Link> children = term.getChildren(); paths.put(trm.getChild().getID(), distance); logger.error("Stack overflow when computing child paths for: " + term.getID() + " for relationships: " + relationshipType); throw new IllegalStateException(e);
protected <T extends CvObject> Class<T> findCvClassforMI( String id ) { Class<T> cvClass; cvClass = mi2Class.get( id ); if ( cvClass != null ) { //then it is one of rootCv return cvClass; } else { OBOObject oboObj = ( OBOObject ) oboSession.getObject( id ); Collection<Link> parentLinks = oboObj.getParents(); for ( Link parentLink : parentLinks ) { String parentId = parentLink.getParent().getID(); return findCvClassforMI( parentId ); } } return cvClass; }
Collection<Link> children = term.getChildren(); paths.put(trm.getChild().getID(), distance); logger.error("Stack overflow when computing child paths for: " + term.getID() + " for relationships: " + relationshipType); throw new IllegalStateException(e);
Term parentTrm = ontologyTerms.get(safeTrim(lnk.getParent().getID())); parentTrm = localTermCache.get(safeTrim(lnk.getParent().getID())); if (parentTrm == null) { parentTrm = tqh.getTermById(safeTrim(lnk.getParent().getID()), null); throw new IllegalStateException(lnk.getParent().getID() + " is not lot local to " + SHORT_NAME + " and is not already loaded in the OLS dabatase. Cannot proceed."); } else { logger.warn(lnk.getParent().getID() + " is not lot local to " + SHORT_NAME + " and is not already loaded in the OLS dabatase. RELATIONSHIP IGNORED."); logger.info("retrieved " + lnk.getParent().getID() + " from OLS database"); localTermCache.put(safeTrim(lnk.getParent().getID()), parentTrm); logger.debug("cached " + lnk.getParent().getID() + " for local reuse if required"); logger.debug("used cached resolved term: " + lnk.getParent().getID());
Term childTrm = ontologyTerms.get(safeTrim(lnk.getChild().getID())); if (childTrm != null) { TermRelationshipBean trb = new TermRelationshipBean();
Term childTrm = ontologyTerms.get(safeTrim(lnk.getChild().getID())); if (childTrm != null) { TermRelationshipBean trb = new TermRelationshipBean();
Term childTrm = ontologyTerms.get(safeTrim(lnk.getChild().getID())); if (childTrm != null) { TermRelationshipBean trb = new TermRelationshipBean();