5729 |
18 Nov 19 |
nicklas |
1 |
package net.sf.basedb.reggie.vcf; |
5729 |
18 Nov 19 |
nicklas |
2 |
|
5729 |
18 Nov 19 |
nicklas |
3 |
/** |
5729 |
18 Nov 19 |
nicklas |
Factory class for extracting information from the |
5729 |
18 Nov 19 |
nicklas |
INFO field of a VCF. Implementations will get notified |
5729 |
18 Nov 19 |
nicklas |
for each ##INFO header via {@link #addInfoHeader(String, String)} |
5729 |
18 Nov 19 |
nicklas |
and then, for each entry, the INFO column via {@link #getInfo(String)} |
5729 |
18 Nov 19 |
nicklas |
8 |
|
5729 |
18 Nov 19 |
nicklas |
@since 4.24 |
5729 |
18 Nov 19 |
nicklas |
10 |
*/ |
5729 |
18 Nov 19 |
nicklas |
11 |
public interface InfoFactory |
5729 |
18 Nov 19 |
nicklas |
12 |
{ |
5729 |
18 Nov 19 |
nicklas |
13 |
|
5729 |
18 Nov 19 |
nicklas |
14 |
/** |
5729 |
18 Nov 19 |
nicklas |
This method is called by the VcfParser once for every |
5729 |
18 Nov 19 |
nicklas |
##INFO header in the VCF. The ID attribute has been |
5729 |
18 Nov 19 |
nicklas |
extracted and is passed as the id parameter. The |
5729 |
18 Nov 19 |
nicklas |
other attributes are not parsed but passed as a |
5729 |
18 Nov 19 |
nicklas |
the data string. The following pattern is |
5729 |
18 Nov 19 |
nicklas |
used to parse the header: ##INFO=<ID=(\w+),(.*)> |
5729 |
18 Nov 19 |
nicklas |
21 |
*/ |
5729 |
18 Nov 19 |
nicklas |
22 |
public void addInfoHeader(String id, String data); |
5729 |
18 Nov 19 |
nicklas |
23 |
|
5729 |
18 Nov 19 |
nicklas |
24 |
/** |
5729 |
18 Nov 19 |
nicklas |
This method is called by the VcfParser once for |
5729 |
18 Nov 19 |
nicklas |
every data line in the VCF with data for the info |
5729 |
18 Nov 19 |
nicklas |
column and the information about the SNP that |
5729 |
18 Nov 19 |
nicklas |
has already been extracted. |
5729 |
18 Nov 19 |
nicklas |
@return An InfoData object or null |
5729 |
18 Nov 19 |
nicklas |
30 |
*/ |
5729 |
18 Nov 19 |
nicklas |
31 |
public InfoData getInfo(String info, SnpData snp); |
5729 |
18 Nov 19 |
nicklas |
32 |
|
5729 |
18 Nov 19 |
nicklas |
33 |
} |