Interface ExternalFileGeneLoaderService

    • Method Detail

      • load

        int load​(String geneFile,
                 String taxonName)
          throws Exception
        Work flow is: The file is first checked to see if readable, and the taxon checked to see it is in Gemma. If validation passes the file is read line by line. Each line equates to a gene and its gene product, which is created from the file details. The gene is then persisted. If successfully loaded taxon flag isGenesLoaded is set to true to indicate that there are genes loaded for this taxon.
        Parameters:
        geneFile - Full path to file containing genes details
        taxonName - taxonName to be associated to this gene, does not have to be a species.
        Returns:
        number of genes loaded
        Throws:
        Exception - Thrown with a file format error or problem in persisting gene to database.
      • load

        int load​(InputStream geneInputStream,
                 String taxonName)
          throws Exception
        Parameters:
        geneInputStream - gene input stream
        taxonName - taxon name
        Returns:
        number of genes loaded
        Throws:
        Exception - Thrown with a file format error or problem in persisting gene to database.