Interface GeneService

    • Method Detail

      • create

        @Secured("GROUP_ADMIN")
        Gene create​(Gene gene)
        Description copied from interface: BaseImmutableService
        Creates the given entity in the persistent storage.
        Specified by:
        create in interface BaseImmutableService<Gene>
        Parameters:
        gene - the entity to be created.
        Returns:
        object referencing the persistent instance of the given entity.
      • remove

        @Secured("GROUP_ADMIN")
        void remove​(Gene gene)
        Description copied from interface: BaseImmutableService
        Removes the given entity from the persistent storage.
        Specified by:
        remove in interface BaseImmutableService<Gene>
        Parameters:
        gene - the entity to be removed.
      • find

        Collection<Gene> find​(PhysicalLocation physicalLocation)
        Find all genes at a physical location. All overlapping genes are returned. The location can be a point or a region. If strand is non-null, only genes on the same strand are returned.
        Parameters:
        physicalLocation - physical location of gene
        Returns:
        all genes at given location
      • findByEnsemblId

        Gene findByEnsemblId​(String exactString)
        Searches for a gene based on its ensembl ID. There is a small amount of genes in our database that have duplicate ensembl IDs. These genes are believed to be somehow unusable anyway, so we ignore those cases at the moment - Aug. 11th 2017.
        Parameters:
        exactString - the ensembl ID that the gene will be looked up by.
        Returns:
        a Gene with the given Ensembl ID.
      • findByNCBIId

        Gene findByNCBIId​(Integer accession)
      • findByOfficialSymbol

        Gene findByOfficialSymbol​(String symbol,
                                  Taxon taxon)
      • findByOfficialSymbolInexact

        Collection<Gene> findByOfficialSymbolInexact​(String officialSymbol)
      • findByOfficialSymbols

        Map<String,​GeneValueObject> findByOfficialSymbols​(Collection<String> query,
                                                                Long taxonId)
        Quickly load exact matches.
        Parameters:
        query - query
        taxonId - taxon id
        Returns:
        map of lower-cased gene symbol to the gene. The actual query that led to the gene is not retained.
      • getCompositeSequenceCountById

        long getCompositeSequenceCountById​(Long id)
      • getCompositeSequences

        @Secured({"IS_AUTHENTICATED_ANONYMOUSLY","AFTER_ACL_ARRAYDESIGN_COLLECTION_READ"})
        Collection<CompositeSequence> getCompositeSequences​(Gene gene,
                                                            ArrayDesign arrayDesign)
        Returns a list of compositeSequences associated with the given gene and array design
        Parameters:
        gene - gene
        arrayDesign - platform
        Returns:
        composite sequences
      • getCompositeSequencesById

        @Secured({"IS_AUTHENTICATED_ANONYMOUSLY","AFTER_ACL_ARRAYDESIGN_COLLECTION_READ"})
        Collection<CompositeSequence> getCompositeSequencesById​(Long id)
        Parameters:
        id - Gemma gene id
        Returns:
        Return probes for a given gene id.
      • loadAll

        Collection<Gene> loadAll​(Taxon taxon)
        Parameters:
        taxon - taxon
        Returns:
        a collection of genes for the specified taxon
      • loadFullyPopulatedValueObject

        GeneValueObject loadFullyPopulatedValueObject​(Long id)
        Returns a detailVO for a geneDd This method may be unnecessary now that we have put all the logic into the GeneService
        Parameters:
        id - The gene id
        Returns:
        GeneDetailsValueObject a representation of that gene
      • loadMicroRNAs

        Collection<Gene> loadMicroRNAs​(Taxon taxon)
        Parameters:
        taxon - taxon
        Returns:
        all the microRNAs for a given taxon. Note query could be slow or inexact due to use of wild card searching of the genes description
      • loadThawed

        Collection<Gene> loadThawed​(Collection<Long> ids)
        Load with objects already thawed.
        Parameters:
        ids - ids
        Returns:
        pre-thawed genes
      • thawAliases

        Gene thawAliases​(Gene gene)
        Parameters:
        gene - gene
        Returns:
        thaw the Aliases, very light version
      • thawLite

        Gene thawLite​(Gene gene)
      • thawLiter

        Gene thawLiter​(Gene gene)
      • removeAll

        @Secured("GROUP_ADMIN")
        int removeAll()