Class RecordReaderConverter


  • public class RecordReaderConverter
    extends Object
    • Method Detail

      • convert

        public static void convert​(RecordReader reader,
                                   RecordWriter writer)
                            throws IOException
        Write all values from the specified record reader to the specified record writer. Closes the record writer on completion
        Parameters:
        reader - Record reader (source of data)
        writer - Record writer (location to write data)
        Throws:
        IOException - If underlying reader/writer throws an exception
      • convert

        public static void convert​(RecordReader reader,
                                   RecordWriter writer,
                                   boolean closeOnCompletion)
                            throws IOException
        Write all values from the specified record reader to the specified record writer. Optionally, close the record writer on completion
        Parameters:
        reader - Record reader (source of data)
        writer - Record writer (location to write data)
        closeOnCompletion - if true: close the record writer once complete, via RecordWriter.close()
        Throws:
        IOException - If underlying reader/writer throws an exception
      • convert

        public static void convert​(SequenceRecordReader reader,
                                   SequenceRecordWriter writer)
                            throws IOException
        Write all sequences from the specified sequence record reader to the specified sequence record writer. Closes the sequence record writer on completion.
        Parameters:
        reader - Sequence record reader (source of data)
        writer - Sequence record writer (location to write data)
        Throws:
        IOException - If underlying reader/writer throws an exception
      • convert

        public static void convert​(SequenceRecordReader reader,
                                   SequenceRecordWriter writer,
                                   boolean closeOnCompletion)
                            throws IOException
        Write all sequences from the specified sequence record reader to the specified sequence record writer. Closes the sequence record writer on completion.
        Parameters:
        reader - Sequence record reader (source of data)
        writer - Sequence record writer (location to write data)
        closeOnCompletion - if true: close the record writer once complete, via SequenceRecordWriter.close()
        Throws:
        IOException - If underlying reader/writer throws an exception