Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions java/vector/src/main/codegen/templates/NullableValueVectors.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,10 @@
* NB: this class is automatically generated from ${.template_name} and ValueVectorTypes.tdd using FreeMarker.
*/
@SuppressWarnings("unused")
public final class ${className} extends BaseDataValueVector implements <#if type.major == "VarLen">VariableWidth<#else>FixedWidth</#if>Vector, NullableVector, FieldVector {
public final class ${className} extends BaseValueVector implements <#if type.major == "VarLen">VariableWidth<#else>FixedWidth</#if>Vector, NullableVector, FieldVector {
private static final org.slf4j.Logger logger = org.slf4j.LoggerFactory.getLogger(${className}.class);

protected final static byte[] emptyByteArray = new byte[]{};
private final FieldReader reader = new ${minor.class}ReaderImpl(${className}.this);

private final String bitsField = "$bits$";
Expand Down Expand Up @@ -217,7 +218,6 @@ public int getBufferSizeFor(final int valueCount) {
+ bits.getBufferSizeFor(valueCount);
}

@Override
public ArrowBuf getBuffer() {
return values.getBuffer();
}
Expand Down Expand Up @@ -286,7 +286,6 @@ public void reset() {
bits.zeroVector();
mutator.reset();
accessor.reset();
super.reset();
}

@Override
Expand Down Expand Up @@ -314,12 +313,10 @@ public void allocateNew(int valueCount) {
accessor.reset();
}

@Override
public void reset() {
bits.zeroVector();
mutator.reset();
accessor.reset();
super.reset();
}

/**
Expand All @@ -332,6 +329,11 @@ public void zeroVector() {
}
</#if>

@Override
public TransferPair getTransferPair(String ref, BufferAllocator allocator, CallBack callBack) {
return getTransferPair(ref, allocator);
}

@Override
public TransferPair getTransferPair(BufferAllocator allocator){
return new TransferImpl(name, allocator);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@

public abstract class BaseDataValueVector extends BaseValueVector implements BufferBacked {

protected final static byte[] emptyByteArray = new byte[]{}; // Nullable vectors use this

public static void load(ArrowFieldNode fieldNode, List<BufferBacked> vectors, List<ArrowBuf> buffers) {
int expectedSize = vectors.size();
if (buffers.size() != expectedSize) {
Expand Down