Class SAMHeaderHadoopUtils.SAMHeaderWriter
java.lang.Object
fr.ens.biologie.genomique.eoulsan.modules.mapping.hadoop.SAMHeaderHadoopUtils.SAMHeaderWriter
- Enclosing class:
- SAMHeaderHadoopUtils
This class allow to save the SAM header read by a mapper.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose(org.apache.hadoop.mapreduce.JobContext context) Close the SAM file header.booleanwriteIfHeaderLine(org.apache.hadoop.mapreduce.JobContext context, String line) Write the line to the SAM header file if the line is a SAM header.
-
Constructor Details
-
SAMHeaderWriter
Constructor.- Parameters:
attemptId- Hadoop task attempt Id
-
-
Method Details
-
writeIfHeaderLine
public boolean writeIfHeaderLine(org.apache.hadoop.mapreduce.JobContext context, String line) throws IOException Write the line to the SAM header file if the line is a SAM header.- Parameters:
context- the Hadoop contextline- the line read- Returns:
- if the line is an header or an empty line
- Throws:
IOException- if an error occurs while writing the SAM file header
-
close
Close the SAM file header.- Parameters:
context- the Hadoop context- Throws:
IOException- if an error occurs while writing the SAM file header
-