Class ColumnAccessors.Decimal18ColumnWriter

All Implemented Interfaces:
ColumnWriter, ScalarWriter, ValueWriter, WriterEvents, WriterPosition
Enclosing class:
ColumnAccessors

public static class ColumnAccessors.Decimal18ColumnWriter extends AbstractFixedWidthWriter.BaseFixedWidthWriter
  • Constructor Details

    • Decimal18ColumnWriter

      public Decimal18ColumnWriter(ValueVector vector)
  • Method Details

    • vector

      public BaseDataValueVector vector()
      Specified by:
      vector in class AbstractScalarWriterImpl
    • width

      public int width()
      Specified by:
      width in class AbstractFixedWidthWriter
    • valueType

      public ValueType valueType()
      Description copied from interface: ScalarWriter
      Describe the type of the value. This is a compression of the value vector type: it describes which method will return the vector value.
      Returns:
      the value type which indicates which get method is valid for the column
    • setDecimal

      public final void setDecimal(BigDecimal value)
      Specified by:
      setDecimal in interface ValueWriter
      Overrides:
      setDecimal in class BaseScalarWriter
    • writeDecimal

      public final void writeDecimal(DrillBuf buf, BigDecimal value)
    • setInt

      public final void setInt(int value)
      Specified by:
      setInt in interface ValueWriter
      Overrides:
      setInt in class BaseScalarWriter
    • setLong

      public final void setLong(long value)
      Specified by:
      setLong in interface ValueWriter
      Overrides:
      setLong in class BaseScalarWriter
    • setDouble

      public final void setDouble(double value)
      Specified by:
      setDouble in interface ValueWriter
      Overrides:
      setDouble in class BaseScalarWriter
    • setFloat

      public final void setFloat(float value)
      Specified by:
      setFloat in interface ValueWriter
      Overrides:
      setFloat in class BaseScalarWriter
    • setValue

      public final void setValue(Object value)
      Description copied from interface: ValueWriter
      Write value to a vector as a Java object of the "native" type for the column. This form is available only on scalar writers. The object must be of the form for the primary write method above.

      Primarily to be used when the code already knows the object type.

      Parameters:
      value - a value that matches the primary setter above, or null to set the column to null
      See Also:
    • setDefaultValue

      public final void setDefaultValue(Object value)
      Description copied from interface: ScalarWriter
      Set the default value to be used to fill empties for this writer. Only valid for required writers: null writers set this is-set bit to 0 and set the data value to 0.
      Parameters:
      value - the value to set. Cannot be null. The type of the value must match that legal for ValueWriter.setValue(Object)
    • copy

      public final void copy(ColumnReader from)
      Description copied from interface: ColumnWriter
      Copy a single value from the given reader, which must be of the same type as this writer.
      Parameters:
      from - reader to provide the data