Package org.apache.drill.exec.vector
Class RepeatedVar16CharVector.Mutator
java.lang.Object
org.apache.drill.exec.vector.BaseValueVector.BaseMutator
org.apache.drill.exec.vector.complex.BaseRepeatedValueVector.BaseRepeatedMutator
org.apache.drill.exec.vector.RepeatedVar16CharVector.Mutator
- All Implemented Interfaces:
RepeatedValueVector.RepeatedMutator,ValueVector.Mutator
- Enclosing class:
RepeatedVar16CharVector
public final class RepeatedVar16CharVector.Mutator
extends BaseRepeatedValueVector.BaseRepeatedMutator
implements RepeatedValueVector.RepeatedMutator
-
Method Summary
Modifier and TypeMethodDescriptionvoidadd(int index, byte[] value) Add an element to the given record index.voidadd(int index, RepeatedVar16CharHolder holder) protected voidadd(int index, Var16CharHolder holder) voidaddSafe(int index, byte[] bytes) voidaddSafe(int index, byte[] bytes, int start, int length) voidvoidaddSafe(int index, NullableVar16CharHolder holder) voidaddSafe(int index, Var16CharHolder holder) voidfillEmpties(int lastWrite, int index) Backfill missing offsets from the given last written position to the given current write position.voidgenerateTestData(int valCount) voidreset()Resets the mutator to pristine state.voidsetSafe(int index, RepeatedVar16CharHolder h) Methods inherited from class org.apache.drill.exec.vector.complex.BaseRepeatedValueVector.BaseRepeatedMutator
getInnerValueCountAt, setValueCount, startNewValueMethods inherited from class org.apache.drill.exec.vector.BaseValueVector.BaseMutator
exchangeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.drill.exec.vector.complex.RepeatedValueVector.RepeatedMutator
startNewValueMethods inherited from interface org.apache.drill.exec.vector.ValueVector.Mutator
exchange, setValueCount
-
Method Details
-
add
public void add(int index, byte[] value) Add an element to the given record index. This is similar to the set() method in other value vectors, except that it permits setting multiple values for a single record.- Parameters:
index- record of the element to addvalue- value to add to the given row
-
addSafe
public void addSafe(int index, byte[] bytes) -
addSafe
public void addSafe(int index, byte[] bytes, int start, int length) -
setSafe
-
addSafe
-
addSafe
-
fillEmpties
public void fillEmpties(int lastWrite, int index) Backfill missing offsets from the given last written position to the given current write position. Used by the "new" size-safe column writers to allow skipping values. The set() and setSafe() do not fill empties. See DRILL-5529.- Parameters:
lastWrite- the position of the last valid write: the offset to be copied forwardindex- the current write position to be initialized
-
addSafe
-
add
-
add
-
generateTestData
public void generateTestData(int valCount) - Specified by:
generateTestDatain interfaceValueVector.Mutator- Overrides:
generateTestDatain classBaseValueVector.BaseMutator
-
reset
public void reset()Description copied from interface:ValueVector.MutatorResets the mutator to pristine state.- Specified by:
resetin interfaceValueVector.Mutator- Overrides:
resetin classBaseValueVector.BaseMutator
-