2009-03-16 06:42:24 +08:00
|
|
|
package org.broadinstitute.sting.gatk.walkers;
|
|
|
|
|
|
|
|
|
|
import net.sf.samtools.SAMRecord;
|
|
|
|
|
import org.broadinstitute.sting.gatk.LocusContext;
|
|
|
|
|
|
2009-03-27 00:22:35 +08:00
|
|
|
public class PrintReadsWalker extends ReadWalker<Integer, Integer> {
|
2009-03-16 06:42:24 +08:00
|
|
|
public Integer map(LocusContext context, SAMRecord read) {
|
|
|
|
|
System.out.println(read.format());
|
|
|
|
|
return 1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public Integer reduceInit() { return 0; }
|
|
|
|
|
|
|
|
|
|
public Integer reduce(Integer value, Integer sum) {
|
|
|
|
|
return value + sum;
|
|
|
|
|
}
|
|
|
|
|
}
|