Class NcbiGeneHistoryParser
java.lang.Object
ubic.gemma.core.loader.util.parser.BasicLineMapParser<String,NcbiGeneHistory>
ubic.gemma.core.loader.genome.gene.ncbi.NcbiGeneHistoryParser
- All Implemented Interfaces:
LineParser<NcbiGeneHistory>,Parser<NcbiGeneHistory>
Parse the NCBI "gene_history" file. File format : tax_id, GeneID,Discontinued_GeneID, Discontinued_Symbol,
Discontinue_Date; (tab is used as a separator, pound sign - start of a comment) File is obtained from
ftp.ncbi.nih.gov.gene/DATA
See ncbi readme
There are two kinds of lines. Lines with a "-" for the GeneID (the majority) seems to be used when the
record was withdrawn (Field is defined as "the current unique identified for a gene"). Lines with a symbol means it
was replaced, so far as I can tell.
- Author:
- paul
-
Field Summary
Fields inherited from class ubic.gemma.core.loader.util.parser.BasicLineMapParser
COMMENT_MARK, logFields inherited from interface ubic.gemma.core.loader.util.parser.LineParser
MIN_PARSED_LINES_FOR_UPDATE, PARSE_ALERT_TIME_FREQUENCY_MSFields inherited from interface ubic.gemma.core.loader.util.parser.Parser
PARSE_ALERT_FREQUENCY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsKey(String key) discontinuedIdForSymbol(String geneSymbol, Integer taxonId) protected StringgetKey(NcbiGeneHistory newItem) parseOneLine(String line) Handle the parsing of a single line from the input.protected voidput(String key, NcbiGeneHistory value) Methods inherited from class ubic.gemma.core.loader.util.parser.BasicLineMapParser
parse, parse, parseMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ubic.gemma.core.loader.util.parser.Parser
getUniqueResult
-
Constructor Details
-
NcbiGeneHistoryParser
public NcbiGeneHistoryParser()
-
-
Method Details
-
containsKey
- Specified by:
containsKeyin classBasicLineMapParser<String,NcbiGeneHistory>
-
get
- Specified by:
getin classBasicLineMapParser<String,NcbiGeneHistory>
-
getKeySet
- Specified by:
getKeySetin classBasicLineMapParser<String,NcbiGeneHistory>
-
getResults
- Specified by:
getResultsin interfaceParser<NcbiGeneHistory>- Specified by:
getResultsin classBasicLineMapParser<String,NcbiGeneHistory> - Returns:
- the results of the parse.
-
parseOneLine
Description copied from interface:LineParserHandle the parsing of a single line from the input.- Specified by:
parseOneLinein interfaceLineParser<NcbiGeneHistory>- Specified by:
parseOneLinein classBasicLineMapParser<String,NcbiGeneHistory> - Parameters:
line- line to parse- Returns:
- parsed object
-
getKey
- Specified by:
getKeyin classBasicLineMapParser<String,NcbiGeneHistory>
-
put
- Specified by:
putin classBasicLineMapParser<String,NcbiGeneHistory>
-
discontinuedIdForSymbol
- Parameters:
geneSymbol- gene symboltaxonId- taxon id- Returns:
- null, or the NCBI ID of the gene that was discontinued.
-