public abstract class AbstractWritableVector extends Object implements WritableColumnVector, Serializable
ColumnVectors, including NULL information and
dictionary. NOTE: if there are some nulls, must set noNulls to false.| Modifier and Type | Field and Description |
|---|---|
protected int |
capacity |
protected Dictionary |
dictionary
The Dictionary for this column.
|
protected int |
elementsAppended
Current write cursor (row index) when appending data.
|
protected boolean |
isAllNull |
protected boolean |
noNulls |
| Constructor and Description |
|---|
AbstractWritableVector(int capacity) |
| Modifier and Type | Method and Description |
|---|---|
void |
addElementsAppended(int num)
Increment number of elements appended by 'num'.
|
int |
getCapacity() |
int |
getElementsAppended() |
boolean |
hasDictionary()
Returns true if this column has a dictionary.
|
boolean |
isAllNull()
Check if all values are null.
|
void |
reserve(int requiredCapacity) |
protected abstract void |
reserveInternal(int newCapacity) |
void |
reset()
Resets the column to default state.
|
void |
setAllNull()
Set all values to null.
|
void |
setDictionary(Dictionary dictionary)
Update the dictionary.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitfillWithNulls, getDictionaryIds, reserveAdditional, reserveDictionaryIds, setNullAt, setNullsgetChildren, isNullAtprotected boolean noNulls
protected boolean isAllNull
protected int elementsAppended
protected int capacity
protected Dictionary dictionary
public void setDictionary(Dictionary dictionary)
setDictionary in interface WritableColumnVectorpublic boolean hasDictionary()
hasDictionary in interface WritableColumnVectorpublic void setAllNull()
WritableColumnVectorsetAllNull in interface WritableColumnVectorpublic boolean isAllNull()
WritableColumnVectorisAllNull in interface WritableColumnVectorpublic int getElementsAppended()
getElementsAppended in interface WritableColumnVectorpublic final void addElementsAppended(int num)
addElementsAppended in interface WritableColumnVectorpublic int getCapacity()
getCapacity in interface ColumnVectorpublic void reset()
WritableColumnVectorreset in interface WritableColumnVectorpublic void reserve(int requiredCapacity)
reserve in interface WritableColumnVectorprotected abstract void reserveInternal(int newCapacity)
Copyright © 2023–2025 The Apache Software Foundation. All rights reserved.