Class SingleVectorState.VariableWidthVectorState
java.lang.Object
org.apache.drill.exec.physical.resultSet.impl.SingleVectorState
org.apache.drill.exec.physical.resultSet.impl.SingleVectorState.SimpleVectorState
org.apache.drill.exec.physical.resultSet.impl.SingleVectorState.VariableWidthVectorState
- All Implemented Interfaces:
VectorState
- Enclosing class:
- SingleVectorState
public static class SingleVectorState.VariableWidthVectorState
extends SingleVectorState.SimpleVectorState
State for a scalar value vector. The vector might be for a simple (non-array)
vector, or might be the payload part of a scalar array (repeated scalar)
vector.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.drill.exec.physical.resultSet.impl.SingleVectorState
SingleVectorState.FixedWidthVectorState, SingleVectorState.IsSetVectorState, SingleVectorState.OffsetVectorState, SingleVectorState.SimpleVectorState, SingleVectorState.VariableWidthVectorState
-
Field Summary
Fields inherited from class org.apache.drill.exec.physical.resultSet.impl.SingleVectorState
backupVector, mainVector, writer
-
Constructor Summary
ConstructorDescriptionVariableWidthVectorState
(ColumnMetadata schema, WriterEvents writer, ValueVector mainVector) -
Method Summary
Modifier and TypeMethodDescriptionint
allocateVector
(ValueVector vector, int cardinality) void
rollover
(int cardinality) A column within the row batch overflowed.Methods inherited from class org.apache.drill.exec.physical.resultSet.impl.SingleVectorState.SimpleVectorState
copyOverflow
Methods inherited from class org.apache.drill.exec.physical.resultSet.impl.SingleVectorState
allocate, close, dump, harvestWithLookAhead, isProjected, parseVectorType, startBatchWithLookAhead, vector, vectorState
-
Constructor Details
-
VariableWidthVectorState
-
-
Method Details
-
allocateVector
- Specified by:
allocateVector
in classSingleVectorState
-
rollover
public void rollover(int cardinality) Description copied from class:SingleVectorState
A column within the row batch overflowed. Prepare to absorb the rest of the in-flight row by rolling values over to a new vector, saving the complete vector for later. This column could have a value for the overflow row, or for some previous row, depending on exactly when and where the overflow occurs. sourceStartIndex: the index of the row that caused the overflow, the values of which should be copied to a new "look-ahead" vector. If the vector is an array, then the overflowIndex is the position of the first element to be moved, and multiple elements may need to move- Specified by:
rollover
in interfaceVectorState
- Overrides:
rollover
in classSingleVectorState
- Parameters:
cardinality
- the number of unique columns in the row
-