public class NullableMapVector extends MapVector implements FieldVector
| Modifier and Type | Class and Description |
|---|---|
protected class |
NullableMapVector.NullableMapTransferPair |
MapVector.MapTransferPair| Modifier and Type | Field and Description |
|---|---|
protected ArrowBuf |
validityBuffer |
fieldType, valueCountallocator, callBack, name| Constructor and Description |
|---|
NullableMapVector(String name,
BufferAllocator allocator,
CallBack callBack)
Deprecated.
|
NullableMapVector(String name,
BufferAllocator allocator,
DictionaryEncoding dictionary,
CallBack callBack)
Deprecated.
|
NullableMapVector(String name,
BufferAllocator allocator,
FieldType fieldType,
CallBack callBack) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
allocateNewSafe()
Allocates new buffers.
|
void |
clear()
Same as
close() |
void |
close()
Close the vector and release the associated buffers.
|
static NullableMapVector |
empty(String name,
BufferAllocator allocator) |
void |
get(int index,
ComplexHolder holder) |
ArrowBuf[] |
getBuffers(boolean clear)
Return the underlying buffers associated with this vector.
|
int |
getBufferSize()
Get the size (number of bytes) of underlying buffers used by this
vector
|
int |
getBufferSizeFor(int valueCount)
Get the potential buffer size for a particular number of records.
|
ArrowBuf |
getDataBuffer()
Gets the underlying buffer associated with data vector
|
long |
getDataBufferAddress()
Gets the starting address of the underlying buffer associated with data vector
|
Field |
getField()
Get information about how this field is materialized.
|
List<ArrowBuf> |
getFieldBuffers()
(same size as getFieldVectors() since it is their content)
|
List<BufferBacked> |
getFieldInnerVectors()
Deprecated.
|
int |
getNullCount()
Returns number of null elements in the vector
|
Object |
getObject(int index)
Get friendly type object from the vector
|
ArrowBuf |
getOffsetBuffer()
Gets the underlying buffer associated with offset vector
|
long |
getOffsetBufferAddress()
Gets the starting address of the underlying buffer associated with offset vector
|
NullableMapReaderImpl |
getReader() |
TransferPair |
getTransferPair(BufferAllocator allocator)
to transfer quota responsibility
|
TransferPair |
getTransferPair(String ref,
BufferAllocator allocator) |
TransferPair |
getTransferPair(String ref,
BufferAllocator allocator,
CallBack callBack) |
ArrowBuf |
getValidityBuffer()
Gets the underlying buffer associated with validity vector
|
long |
getValidityBufferAddress()
Gets the starting address of the underlying buffer associated with validity vector
|
int |
getValueCapacity()
Get the current value capacity for the vector
|
NullableMapWriter |
getWriter() |
boolean |
isNull(int index)
Check whether an element in the vector is null
|
int |
isSet(int index) |
void |
loadFieldBuffers(ArrowFieldNode fieldNode,
List<ArrowBuf> ownBuffers)
loads data in the vectors
(ownBuffers must be the same size as getFieldVectors())
|
TransferPair |
makeTransferPair(ValueVector to)
makes a new transfer pair used to transfer underlying buffers
|
void |
reAlloc()
Allocate new buffer with double capacity, and copy data into the new buffer.
|
void |
reset() |
void |
setIndexDefined(int index) |
void |
setInitialCapacity(int numRecords)
Set the initial record capacity
|
void |
setNull(int index) |
void |
setValueCount(int valueCount)
Set number of values in the vector
|
copyFromSafe, fieldNameIterator, getChildrenFromFields, getMinorType, getValueCount, getVectorById, initializeChildrenFromFields, supportsDirectReadadd, addOrGet, getChild, getChildByOrdinal, getChildFieldNames, getChildren, getChildVectorWithOrdinal, getPrimitiveVectors, iterator, putChild, putVector, sizeaddOrGetList, addOrGetMap, addOrGetUnion, allocateNew, getAllocator, getChild, typeifyclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetChildrenFromFields, initializeChildrenFromFieldsallocateNew, getAllocator, getMinorType, getValueCountprotected ArrowBuf validityBuffer
@Deprecated public NullableMapVector(String name, BufferAllocator allocator, CallBack callBack)
@Deprecated public NullableMapVector(String name, BufferAllocator allocator, DictionaryEncoding dictionary, CallBack callBack)
public NullableMapVector(String name, BufferAllocator allocator, FieldType fieldType, CallBack callBack)
public static NullableMapVector empty(String name, BufferAllocator allocator)
public Field getField()
ValueVectorgetField in interface ValueVectorgetField in class MapVectorpublic void loadFieldBuffers(ArrowFieldNode fieldNode, List<ArrowBuf> ownBuffers)
FieldVectorloadFieldBuffers in interface FieldVectorfieldNode - the fieldNodeownBuffers - the buffers for this Field (own buffers only, children not included)public List<ArrowBuf> getFieldBuffers()
FieldVectorgetFieldBuffers in interface FieldVector@Deprecated public List<BufferBacked> getFieldInnerVectors()
getFieldInnerVectors in interface FieldVectorpublic NullableMapReaderImpl getReader()
getReader in interface ValueVectorgetReader in class MapVectorfield reader that supports reading values
from this vector.public NullableMapWriter getWriter()
public TransferPair getTransferPair(BufferAllocator allocator)
ValueVectorgetTransferPair in interface ValueVectorgetTransferPair in class MapVectorallocator - the target allocatortransfer pair, creating a new target vector of
the same type.public TransferPair makeTransferPair(ValueVector to)
ValueVectormakeTransferPair in interface ValueVectormakeTransferPair in class MapVectorto - the target for the transfertransfer pair that is used to transfer underlying
buffers into the target vector.public TransferPair getTransferPair(String ref, BufferAllocator allocator)
getTransferPair in interface ValueVectorgetTransferPair in class MapVectorpublic TransferPair getTransferPair(String ref, BufferAllocator allocator, CallBack callBack)
getTransferPair in interface ValueVectorgetTransferPair in class MapVectorpublic int getValueCapacity()
getValueCapacity in interface ValueVectorgetValueCapacity in class MapVectorpublic ArrowBuf[] getBuffers(boolean clear)
getBuffers in interface ValueVectorgetBuffers in class AbstractMapVectorclear - Whether to clear vector before returning; the buffers will still be refcounted
but the returned array will be the only reference to thembuffers that is used by this
vector instance.public void close()
close in interface Closeableclose in interface AutoCloseableclose in interface ValueVectorclose in class MapVectorpublic void clear()
close()clear in interface ValueVectorclear in class MapVectorpublic int getBufferSize()
getBufferSize in interface ValueVectorgetBufferSize in class MapVectorpublic int getBufferSizeFor(int valueCount)
getBufferSizeFor in interface ValueVectorgetBufferSizeFor in class MapVectorvalueCount - desired number of elements in the vectorpublic void setInitialCapacity(int numRecords)
ValueVectorsetInitialCapacity in interface ValueVectorsetInitialCapacity in class MapVectornumRecords - the initial record capacity.public boolean allocateNewSafe()
ValueVectorallocateNewSafe in interface ValueVectorallocateNewSafe in class AbstractMapVectorpublic void reAlloc()
ValueVectorreAlloc in interface ValueVectorreAlloc in class AbstractMapVectorpublic long getValidityBufferAddress()
FieldVectorgetValidityBufferAddress in interface FieldVectorpublic long getDataBufferAddress()
FieldVectorgetDataBufferAddress in interface FieldVectorpublic long getOffsetBufferAddress()
FieldVectorgetOffsetBufferAddress in interface FieldVectorpublic ArrowBuf getValidityBuffer()
ValueVectorgetValidityBuffer in interface ValueVectorgetValidityBuffer in class MapVectorpublic ArrowBuf getDataBuffer()
ValueVectorgetDataBuffer in interface ValueVectorgetDataBuffer in class MapVectorpublic ArrowBuf getOffsetBuffer()
ValueVectorgetOffsetBuffer in interface ValueVectorgetOffsetBuffer in class MapVectorpublic Object getObject(int index)
ValueVectorgetObject in interface ValueVectorgetObject in class MapVectorpublic void get(int index,
ComplexHolder holder)
public int getNullCount()
ValueVectorgetNullCount in interface ValueVectorgetNullCount in class MapVectorpublic boolean isNull(int index)
ValueVectorisNull in interface ValueVectorisNull in class MapVectorpublic int isSet(int index)
public void setIndexDefined(int index)
public void setNull(int index)
public void setValueCount(int valueCount)
ValueVectorsetValueCount in interface ValueVectorsetValueCount in class MapVectorpublic void reset()
Copyright © 2017 The Apache Software Foundation. All rights reserved.