Class SAMHeaderHadoopUtils.SAMHeaderWriter

java.lang.Object
fr.ens.biologie.genomique.eoulsan.modules.mapping.hadoop.SAMHeaderHadoopUtils.SAMHeaderWriter
Enclosing class:
SAMHeaderHadoopUtils

public static class SAMHeaderHadoopUtils.SAMHeaderWriter extends Object
This class allow to save the SAM header read by a mapper.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    close(org.apache.hadoop.mapreduce.JobContext context)
    Close the SAM file header.
    boolean
    writeIfHeaderLine(org.apache.hadoop.mapreduce.JobContext context, String line)
    Write the line to the SAM header file if the line is a SAM header.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • SAMHeaderWriter

      public SAMHeaderWriter(String attemptId)
      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 context
      line - 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

      public void close(org.apache.hadoop.mapreduce.JobContext context) throws IOException
      Close the SAM file header.
      Parameters:
      context - the Hadoop context
      Throws:
      IOException - if an error occurs while writing the SAM file header