public class BAMRecordReader extends org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>
| Constructor and Description |
|---|
BAMRecordReader() |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
org.apache.hadoop.io.LongWritable |
getCurrentKey() |
SAMRecordWritable |
getCurrentValue() |
static long |
getKey(int refIdx,
int alignmentStart) |
static long |
getKey(htsjdk.samtools.SAMRecord rec)
Note: this is the only getKey function that handles unmapped reads
specially!
|
static long |
getKey0(int refIdx,
int alignmentStart0) |
float |
getProgress()
Unless the end has been reached, this only takes file position into
account, not the position within the block.
|
void |
initialize(org.apache.hadoop.mapreduce.InputSplit spl,
org.apache.hadoop.mapreduce.TaskAttemptContext ctx) |
boolean |
nextKeyValue() |
public static long getKey(htsjdk.samtools.SAMRecord rec)
public static long getKey(int refIdx,
int alignmentStart)
alignmentStart - 1-based leftmost coordinate.public static long getKey0(int refIdx,
int alignmentStart0)
alignmentStart0 - 0-based leftmost coordinate.public void initialize(org.apache.hadoop.mapreduce.InputSplit spl,
org.apache.hadoop.mapreduce.TaskAttemptContext ctx)
throws IOException
initialize in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>IOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>IOExceptionpublic float getProgress()
getProgress in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>public org.apache.hadoop.io.LongWritable getCurrentKey()
getCurrentKey in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>public SAMRecordWritable getCurrentValue()
getCurrentValue in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>public boolean nextKeyValue()
nextKeyValue in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,SAMRecordWritable>Copyright © 2016. All rights reserved.