Package org.apache.drill.exec.vector
Class Decimal38SparseVector.Mutator
java.lang.Object
org.apache.drill.exec.vector.BaseValueVector.BaseMutator
org.apache.drill.exec.vector.Decimal38SparseVector.Mutator
- All Implemented Interfaces:
ValueVector.Mutator
- Enclosing class:
- Decimal38SparseVector
Decimal38Sparse.Mutator implements a mutable vector of fixed width values.
Elements in the vector are accessed by position from the logical start of
the vector. Values should be pushed onto the vector sequentially, but may
be randomly accessed.
- The width of each element is
Decimal38SparseVector.VALUE_WIDTH
(= 24) byte(s). - The equivalent Java primitive is 'DrillBuf'
-
Method Summary
Modifier and TypeMethodDescriptionvoid
generateTestData
(int count) void
void
Set the element at the given index to the given value.void
set
(int index, BigDecimal value) void
set
(int index, Decimal38SparseHolder holder) void
void
void
setSafe
(int index, BigDecimal value) void
setSafe
(int index, Decimal38SparseHolder holder) void
setSafe
(int index, NullableDecimal38SparseHolder holder) void
setValueCount
(int valueCount) Sets the number of values that is stored in this vector to the given value count.Methods inherited from class org.apache.drill.exec.vector.BaseValueVector.BaseMutator
exchange, reset
-
Method Details
-
set
Set the element at the given index to the given value. Note that widths smaller than 32 bits are handled by the DrillBuf interface.- Parameters:
index
- position of the bit to setvalue
- value to set
-
setSafe
-
setSafe
-
set
-
setSafe
-
setSafe
-
set
-
setSafe
-
set
-
generateTestData
public void generateTestData(int count) - Specified by:
generateTestData
in interfaceValueVector.Mutator
- Overrides:
generateTestData
in classBaseValueVector.BaseMutator
-
setValueCount
public void setValueCount(int valueCount) Description copied from interface:ValueVector.Mutator
Sets the number of values that is stored in this vector to the given value count. WARNING! Once the valueCount is set, the vector should be considered immutable.- Parameters:
valueCount
- value count to set.
-