package com.twitter.elephantbird.mapred.output;

import java.io.IOException;

import com.twitter.elephantbird.mapreduce.io.BinaryBlockWriter;
import com.twitter.elephantbird.mapreduce.io.BinaryWritable;

import org.apache.hadoop.io.NullWritable;
import org.apache.hadoop.mapred.RecordWriter;
import org.apache.hadoop.mapred.Reporter;

/**
 * A writer for LZO-encoded blocks of protobuf or Thrift objects, generally read by
 * a ProtobufBlockWriter or similar.
 */
public class DeprecatedLzoBinaryBlockRecordWriter<M, W extends BinaryWritable<M>>
    implements RecordWriter<NullWritable, W> {

  private BinaryBlockWriter<M> writer_;

  public DeprecatedLzoBinaryBlockRecordWriter(BinaryBlockWriter<M> writer) {
    writer_ = writer;
  }

  public void write(NullWritable nullWritable, W writable)
      throws IOException {
    writer_.write(writable.get());
  }

  public void close(Reporter reporter) throws IOException {
    writer_.finish();
    writer_.close();
  }
}

@@ -628,11 +628,10 @@
 iter
-_
 ;%0A
+
 %0A  p
@@ -708,23 +708,27 @@
 ) %7B%0A    
+this.
 writer
-_
  = write
@@ -831,17 +831,16 @@
   writer
-_
 .write(w
@@ -930,17 +930,16 @@
   writer
-_
 .finish(
@@ -955,9 +955,8 @@
 iter
-_
 .clo

Remove ugly underscore.