Class RecordConsumerLoggingWrapper

java.lang.Object
org.apache.parquet.io.api.RecordConsumer
org.apache.parquet.io.RecordConsumerLoggingWrapper

public class RecordConsumerLoggingWrapper extends RecordConsumer
This class can be used to wrap an actual RecordConsumer and log all calls
  • Constructor Summary

    Constructors
    Constructor
    Description
    all calls a delegate to the wrapped delegate
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add a binary value in the current field
    void
    addBoolean(boolean value)
    add a boolean value in the current field
    void
    addDouble(double value)
    add a double value in the current field
    void
    addFloat(float value)
    add a float value in the current field
    void
    addInteger(int value)
    add an int value in the current field
    void
    addLong(long value)
    add a long value in the current field
    void
    endField(String field, int index)
    end of a field in a group or message
    void
    end of a group in a field
    void
    end of a record
    void
    NoOps by default Subclass class can implement its own flushing logic
    void
    startField(String field, int index)
    start of a field in a group or message if the field is repeated the field is started only once and all values added in between start and end
    void
    start of a group in a field
    void
    start a new record

    Methods inherited from class java.lang.Object

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

    • RecordConsumerLoggingWrapper

      public RecordConsumerLoggingWrapper(RecordConsumer delegate)
      all calls a delegate to the wrapped delegate
      Parameters:
      delegate - a wrapped record consumer that does the real work
  • Method Details

    • startField

      public void startField(String field, int index)
      start of a field in a group or message if the field is repeated the field is started only once and all values added in between start and end
      Specified by:
      startField in class RecordConsumer
      Parameters:
      field - name of the field
      index - of the field in the group or message
    • startGroup

      public void startGroup()
      start of a group in a field
      Specified by:
      startGroup in class RecordConsumer
    • addInteger

      public void addInteger(int value)
      add an int value in the current field
      Specified by:
      addInteger in class RecordConsumer
      Parameters:
      value - an int value
    • addLong

      public void addLong(long value)
      add a long value in the current field
      Specified by:
      addLong in class RecordConsumer
      Parameters:
      value - a long value
    • addBoolean

      public void addBoolean(boolean value)
      add a boolean value in the current field
      Specified by:
      addBoolean in class RecordConsumer
      Parameters:
      value - a boolean value
    • addBinary

      public void addBinary(Binary value)
      add a binary value in the current field
      Specified by:
      addBinary in class RecordConsumer
      Parameters:
      value - a binary value
    • addFloat

      public void addFloat(float value)
      add a float value in the current field
      Specified by:
      addFloat in class RecordConsumer
      Parameters:
      value - a float value
    • addDouble

      public void addDouble(double value)
      add a double value in the current field
      Specified by:
      addDouble in class RecordConsumer
      Parameters:
      value - a double value
    • flush

      public void flush()
      NoOps by default Subclass class can implement its own flushing logic
      Overrides:
      flush in class RecordConsumer
    • endGroup

      public void endGroup()
      end of a group in a field
      Specified by:
      endGroup in class RecordConsumer
    • endField

      public void endField(String field, int index)
      end of a field in a group or message
      Specified by:
      endField in class RecordConsumer
      Parameters:
      field - name of the field
      index - of the field in the group or message
    • startMessage

      public void startMessage()
      start a new record
      Specified by:
      startMessage in class RecordConsumer
    • endMessage

      public void endMessage()
      end of a record
      Specified by:
      endMessage in class RecordConsumer