use of ubic.gemma.core.genome.gene.GOGroupValueObject in project Gemma by PavlidisLab.
the class GeneSetSearchImpl method findGeneSetValueObjectByGoId.
@Override
public GOGroupValueObject findGeneSetValueObjectByGoId(String goId, Long taxonId) {
// shouldn't need to set the taxon here, should be taken care of when creating the value object
Taxon taxon;
if (taxonId != null) {
taxon = taxonService.load(taxonId);
if (taxon == null) {
GeneSetSearchImpl.log.warn("No such taxon with id=" + taxonId);
} else {
GeneSet result = this.findByGoId(goId, taxonService.load(taxonId));
if (result == null) {
GeneSetSearchImpl.log.warn("No matching gene set found for: " + goId);
return null;
}
GOGroupValueObject ggvo = geneSetValueObjectHelper.convertToGOValueObject(result, goId, goId);
ggvo.setTaxonId(taxon.getId());
ggvo.setTaxonName(taxon.getCommonName());
return ggvo;
}
}
return null;
}
Aggregations