Class NcbiGeneInfoParser
java.lang.Object
ubic.gemma.core.loader.util.parser.BasicLineMapParser<String,NCBIGeneInfo>
ubic.gemma.core.loader.genome.gene.ncbi.NcbiGeneInfoParser
- All Implemented Interfaces:
LineParser<NCBIGeneInfo>,Parser<NCBIGeneInfo>,QueuingParser<String>
public class NcbiGeneInfoParser
extends BasicLineMapParser<String,NCBIGeneInfo>
implements QueuingParser<String>
Class to parse the gene_info file from NCBI Gene. See readme for details
of the format.
- Author:
- pavlidis
-
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) getKey(NCBIGeneInfo newItem) voidparse(InputStream inputStream, BlockingQueue<String> queue) Parse an input stream, storing the results in the passed queue (which can be used by a consumer)parseOneLine(String line) Handle the parsing of a single line from the input.protected voidput(String key, NCBIGeneInfo value) voidsetFilter(boolean filter) voidsetSupportedTaxa(Collection<Integer> ncbiTaxonIds) 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
-
NcbiGeneInfoParser
public NcbiGeneInfoParser()
-
-
Method Details
-
containsKey
- Specified by:
containsKeyin classBasicLineMapParser<String,NCBIGeneInfo>
-
get
- Specified by:
getin classBasicLineMapParser<String,NCBIGeneInfo>
-
getKeySet
- Specified by:
getKeySetin classBasicLineMapParser<String,NCBIGeneInfo>
-
getResults
- Specified by:
getResultsin interfaceParser<NCBIGeneInfo>- Specified by:
getResultsin classBasicLineMapParser<String,NCBIGeneInfo> - 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<NCBIGeneInfo>- Specified by:
parseOneLinein classBasicLineMapParser<String,NCBIGeneInfo> - Parameters:
line- line to parse- Returns:
- parsed object
-
getKey
- Specified by:
getKeyin classBasicLineMapParser<String,NCBIGeneInfo>
-
put
- Specified by:
putin classBasicLineMapParser<String,NCBIGeneInfo>
-
parse
Description copied from interface:QueuingParserParse an input stream, storing the results in the passed queue (which can be used by a consumer)- Specified by:
parsein interfaceQueuingParser<String>- Parameters:
inputStream- input streamqueue- queue- Throws:
IOException- IO problems
-
setFilter
public void setFilter(boolean filter) -
setSupportedTaxa
- Parameters:
ncbiTaxonIds- Taxon IDs (NCBI, not Gemma ids) e.g. 9606 for H. sapiens
-