Class GeneSearchServiceImpl
java.lang.Object
ubic.gemma.persistence.service.genome.gene.GeneSearchServiceImpl
- All Implemented Interfaces:
GeneSearchService
Service for searching genes (and gene sets)
- Author:
- tvrossum
-
Constructor Summary
ConstructorsConstructorDescriptionGeneSearchServiceImpl
(SearchService searchService, gemma.gsec.SecurityService securityService, TaxonService taxonService, GeneSetSearch geneSetSearch, GeneSetService geneSetService, GeneService geneService, GeneOntologyService geneOntologyService, GeneSetValueObjectHelper geneSetValueObjectHelper) -
Method Summary
Modifier and TypeMethodDescriptiongetGenesByGOId
(String goId, Long taxonId) get all genes in the given taxon that are annotated with the given go id, including its child terms in the hierarchygetGOGroupGenes
(String goQuery, Taxon taxon) searchGenesAndGeneGroups
(String query, Long taxonId) searchMultipleGenes
(String query, Long taxonId) Search for multiple genes at once.searchMultipleGenesGetMap
(Collection<String> query, Long taxonId) Search for multiple genes at once.
-
Constructor Details
-
GeneSearchServiceImpl
public GeneSearchServiceImpl() -
GeneSearchServiceImpl
@Autowired public GeneSearchServiceImpl(SearchService searchService, gemma.gsec.SecurityService securityService, TaxonService taxonService, GeneSetSearch geneSetSearch, GeneSetService geneSetService, GeneService geneService, GeneOntologyService geneOntologyService, GeneSetValueObjectHelper geneSetValueObjectHelper)
-
-
Method Details
-
getGenesByGOId
Description copied from interface:GeneSearchService
get all genes in the given taxon that are annotated with the given go id, including its child terms in the hierarchy- Specified by:
getGenesByGOId
in interfaceGeneSearchService
- Parameters:
goId
- GO id that must be in the format "GO_#######"taxonId
- a taxan ID to retrieve results from, or null for genes in any taxon- Returns:
- empty if goId was blank or taxonId didn't correspond to a taxon
-
getGOGroupGenes
public Collection<Gene> getGOGroupGenes(String goQuery, @Nullable Taxon taxon) throws SearchException - Specified by:
getGOGroupGenes
in interfaceGeneSearchService
- Throws:
SearchException
-
searchGenesAndGeneGroups
public Collection<SearchResultDisplayObject> searchGenesAndGeneGroups(String query, @Nullable Long taxonId) throws SearchException - Specified by:
searchGenesAndGeneGroups
in interfaceGeneSearchService
- Throws:
SearchException
-
searchMultipleGenes
public Collection<GeneValueObject> searchMultipleGenes(String query, Long taxonId) throws IOException, SearchException Description copied from interface:GeneSearchService
Search for multiple genes at once. This attempts to limit the number of genes per query to only one.- Specified by:
searchMultipleGenes
in interfaceGeneSearchService
- Parameters:
query
- A list of gene names (symbols), one per line.taxonId
- taxon id- Returns:
- collection of gene value objects
- Throws:
IOException
- when there are IO problemsSearchException
-
searchMultipleGenesGetMap
public Map<String,GeneValueObject> searchMultipleGenesGetMap(Collection<String> query, Long taxonId) throws SearchException Description copied from interface:GeneSearchService
Search for multiple genes at once. This attempts to limit the number of genes per query to only one.- Specified by:
searchMultipleGenesGetMap
in interfaceGeneSearchService
- Parameters:
query
- gene names (symbols)taxonId
- taxon id- Returns:
- query with match. Null values means nothing was found for that key (query)
- Throws:
SearchException
-