Package org.apache.drill.exec.vector
Class RepeatedUInt4Vector
java.lang.Object
org.apache.drill.exec.vector.BaseValueVector
org.apache.drill.exec.vector.complex.BaseRepeatedValueVector
org.apache.drill.exec.vector.RepeatedUInt4Vector
- All Implemented Interfaces:
Closeable,AutoCloseable,Iterable<ValueVector>,ContainerVectorLike,RepeatedFixedWidthVectorLike,RepeatedValueVector,ValueVector
public final class RepeatedUInt4Vector
extends BaseRepeatedValueVector
implements RepeatedFixedWidthVectorLike
RepeatedUInt4 implements a vector with multiple values per row (e.g. JSON array or
repeated protobuf field). The implementation uses an additional value vectors to convert
the index offset to the underlying element offset. The count of values comes from subtracting
two successive offsets.
NB: this class is automatically generated from RepeatedValueVectors.java and ValueVectorTypes.tdd using FreeMarker.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionfinal classfinal classNested classes/interfaces inherited from class org.apache.drill.exec.vector.complex.BaseRepeatedValueVector
BaseRepeatedValueVector.BaseRepeatedAccessor, BaseRepeatedValueVector.BaseRepeatedMutator, BaseRepeatedValueVector.BaseRepeatedValueVectorTransferPair<T extends BaseRepeatedValueVector>Nested classes/interfaces inherited from class org.apache.drill.exec.vector.BaseValueVector
BaseValueVector.BaseAccessor, BaseValueVector.BaseMutatorNested classes/interfaces inherited from interface org.apache.drill.exec.vector.complex.RepeatedValueVector
RepeatedValueVector.RepeatedAccessor, RepeatedValueVector.RepeatedMutator -
Field Summary
Fields inherited from class org.apache.drill.exec.vector.complex.BaseRepeatedValueVector
DATA_VECTOR_NAME, DEFAULT_DATA_VECTOR, offsets, OFFSETS_FIELD, OFFSETS_VECTOR_NAME, vectorFields inherited from class org.apache.drill.exec.vector.BaseValueVector
allocator, field, INITIAL_VALUE_ALLOCATION, MAX_ALLOCATION_SIZEFields inherited from interface org.apache.drill.exec.vector.complex.RepeatedValueVector
DEFAULT_REPEAT_PER_RECORDFields inherited from interface org.apache.drill.exec.vector.ValueVector
BITS_VECTOR_NAME, MAX_BUFFER_SIZE, MAX_ROW_COUNT, MIN_ROW_COUNT, VALUES_VECTOR_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddOrGetVector(VectorDescriptor descriptor) Creates and adds a child vector if none with the same name exists, else returns the vector instance.voidAllocate new buffers.voidallocateNew(int valueCount, int innerValueCount) Allocate a new memory space for this vector.booleanAllocates new buffers.voidcopyEntry(int toIndex, ValueVector from, int fromIndex) voidcopyFrom(int inIndex, int outIndex, RepeatedUInt4Vector v) voidcopyFromSafe(int inIndex, int outIndex, RepeatedUInt4Vector v) Returns anaccessorthat is used to read from this vector instance.Returns anmutatorthat is used to write to this vector instance.Returns afield readerthat supports reading values from this vector.getTransferPair(String ref, BufferAllocator allocator) getTransferPair(BufferAllocator allocator) Returns atransfer pair, creating a new target vector of the same type.Returns a newtransfer pairthat is used to transfer underlying buffers into the target vector.voidsplitAndTransferTo(int startIndex, int groups, RepeatedUInt4Vector to) voidtransferTo(RepeatedUInt4Vector target) Methods inherited from class org.apache.drill.exec.vector.complex.BaseRepeatedValueVector
clear, collectLedgers, exchange, getAllocatedSize, getBuffers, getBufferSize, getBufferSizeFor, getMetadataBuilder, getOffsetVector, getPayloadByteCount, getValueCapacity, iterator, load, replaceDataVector, setChildVector, setInitialCapacity, sizeMethods inherited from class org.apache.drill.exec.vector.BaseValueVector
checkBufRefs, close, fillBitsVector, getAllocator, getField, getField, getMetadata, toNullable, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliteratorMethods inherited from interface org.apache.drill.exec.vector.ValueVector
close, getAllocator, getField, getMetadata, toNullable
-
Constructor Details
-
RepeatedUInt4Vector
-
-
Method Details
-
getMutator
Description copied from interface:ValueVectorReturns anmutatorthat is used to write to this vector instance.- Specified by:
getMutatorin interfaceRepeatedValueVector- Specified by:
getMutatorin interfaceValueVector
-
getAccessor
Description copied from interface:ValueVectorReturns anaccessorthat is used to read from this vector instance.- Specified by:
getAccessorin interfaceRepeatedValueVector- Specified by:
getAccessorin interfaceValueVector
-
getReader
Description copied from interface:ValueVectorReturns afield readerthat supports reading values from this vector.- Specified by:
getReaderin interfaceValueVector
-
getDataVector
- Specified by:
getDataVectorin interfaceRepeatedValueVector- Overrides:
getDataVectorin classBaseRepeatedValueVector- Returns:
- the underlying data vector or null if none exists.
-
getTransferPair
Description copied from interface:ValueVectorReturns atransfer pair, creating a new target vector of the same type.- Specified by:
getTransferPairin interfaceValueVector- Overrides:
getTransferPairin classBaseValueVector
-
getTransferPair
- Specified by:
getTransferPairin interfaceValueVector
-
makeTransferPair
Description copied from interface:ValueVectorReturns a newtransfer pairthat is used to transfer underlying buffers into the target vector.- Specified by:
makeTransferPairin interfaceValueVector
-
addOrGetVector
Description copied from interface:ContainerVectorLikeCreates and adds a child vector if none with the same name exists, else returns the vector instance.- Specified by:
addOrGetVectorin interfaceContainerVectorLike- Overrides:
addOrGetVectorin classBaseRepeatedValueVector- Parameters:
descriptor- vector descriptor- Returns:
- result of operation wrapping vector corresponding to the given descriptor and whether it's newly created
-
transferTo
-
splitAndTransferTo
-
copyFrom
-
copyFromSafe
-
copyEntry
- Specified by:
copyEntryin interfaceValueVector
-
allocateNewSafe
public boolean allocateNewSafe()Description copied from interface:ValueVectorAllocates new buffers. ValueVector implements logic to determine how much to allocate.- Specified by:
allocateNewSafein interfaceValueVector- Overrides:
allocateNewSafein classBaseRepeatedValueVector- Returns:
- Returns true if allocation was successful.
-
allocateNew
public void allocateNew()Description copied from interface:ValueVectorAllocate new buffers. ValueVector implements logic to determine how much to allocate.- Specified by:
allocateNewin interfaceValueVector
-
allocateNew
public void allocateNew(int valueCount, int innerValueCount) Description copied from interface:RepeatedFixedWidthVectorLikeAllocate a new memory space for this vector. Must be called prior to using the ValueVector.- Specified by:
allocateNewin interfaceRepeatedFixedWidthVectorLike- Parameters:
valueCount- Number of separate repeating groupings.innerValueCount- Number of supported values in the vector.
-