Module org.elasticsearch.compute
Class LongMul1kArrowBufVector
java.lang.Object
org.elasticsearch.compute.data.AbstractNonThreadSafeRefCounted
org.elasticsearch.compute.data.arrow.AbstractArrowBufVector<LongVector,LongBlock>
org.elasticsearch.compute.data.arrow.LongMul1kArrowBufVector
- All Implemented Interfaces:
Closeable,AutoCloseable,org.apache.lucene.util.Accountable,LongVector,Vector,org.elasticsearch.core.RefCounted,org.elasticsearch.core.Releasable
public final class LongMul1kArrowBufVector
extends AbstractArrowBufVector<LongVector,LongBlock>
implements LongVector
Implementation of LongVector backed by an Arrow buffer holding timestamps in seconds or microseconds, converted to millis or nanos.
This class is generated. Edit X-ArrowBufVector.java.st instead.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.compute.data.LongVector
LongVector.Builder, LongVector.FixedBuilderNested classes/interfaces inherited from interface org.elasticsearch.compute.data.Vector
Vector.Builder -
Field Summary
Fields inherited from class org.elasticsearch.compute.data.arrow.AbstractArrowBufVector
blockFactory, closed, positionCount, valueBufferFields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLEFields inherited from interface org.elasticsearch.core.RefCounted
ALWAYS_REFERENCEDFields inherited from interface org.elasticsearch.compute.data.Vector
SERIALIZE_VECTOR_ARRAY, SERIALIZE_VECTOR_BIG_ARRAY, SERIALIZE_VECTOR_CONSTANT, SERIALIZE_VECTOR_ORDINAL, SERIALIZE_VECTOR_VALUES -
Constructor Summary
ConstructorsConstructorDescriptionLongMul1kArrowBufVector(org.apache.arrow.memory.ArrowBuf valueBuffer, int positionCount, BlockFactory blockFactory) Create an ArrowBuf vector based on the constituents of an ArrowValueVector. -
Method Summary
Modifier and TypeMethodDescriptionprotected ArrowBufBlockConstructor<LongBlock> protected intbyteSize()Returns the element type of this vector.longgetLong(int valueIndex) org.elasticsearch.core.ReleasableIterator<LongBlock> lookup(IntBlock positions, ByteSizeValue targetBlockSize) Builds an Iterator of newBlocks with the sameVector.elementType()as thisVectorwhose values are copied from positions in this Vector.static LongMul1kArrowBufVectorof(org.apache.arrow.vector.FixedWidthVector arrowVector, BlockFactory blockFactory) slice(int beginInclusive, int endExclusive) Return a subset of this vector frombeginInclusivetoendExclusive.protected ArrowBufVectorConstructor<LongVector> Methods inherited from class org.elasticsearch.compute.data.arrow.AbstractArrowBufVector
allowPassingToDifferentDriver, asBlock, blockFactory, closeInternal, filter, getPositionCount, isConstant, keepMask, ramBytesUsed, releaseBuffers, retainBuffersMethods inherited from class org.elasticsearch.compute.data.AbstractNonThreadSafeRefCounted
close, decRef, hasReferences, incRef, isReleased, tryIncRefMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.lucene.util.Accountable
getChildResources, ramBytesUsedMethods inherited from interface org.elasticsearch.compute.data.LongVector
asBlock, copyTo, deepCopy, equals, filter, hashCode, keepMask, writeToMethods inherited from interface org.elasticsearch.core.RefCounted
decRef, hasReferences, incRef, mustIncRef, tryIncRefMethods inherited from interface org.elasticsearch.core.Releasable
closeMethods inherited from interface org.elasticsearch.compute.data.Vector
allowPassingToDifferentDriver, blockFactory, getPositionCount, isConstant, isReleased
-
Constructor Details
-
LongMul1kArrowBufVector
public LongMul1kArrowBufVector(org.apache.arrow.memory.ArrowBuf valueBuffer, int positionCount, BlockFactory blockFactory) Create an ArrowBuf vector based on the constituents of an ArrowValueVector. The caller must retain the buffers if they are shared with other blocks or Arrow vectors.
-
-
Method Details
-
of
public static LongMul1kArrowBufVector of(org.apache.arrow.vector.FixedWidthVector arrowVector, BlockFactory blockFactory) -
vectorConstructor
- Specified by:
vectorConstructorin classAbstractArrowBufVector<LongVector,LongBlock>
-
blockConstructor
- Specified by:
blockConstructorin classAbstractArrowBufVector<LongVector,LongBlock>
-
getLong
public long getLong(int valueIndex) - Specified by:
getLongin interfaceLongVector
-
byteSize
protected int byteSize()- Specified by:
byteSizein classAbstractArrowBufVector<LongVector,LongBlock>
-
elementType
Description copied from interface:VectorReturns the element type of this vector.- Specified by:
elementTypein interfaceVector- Returns:
- the element type of this vector
-
lookup
public org.elasticsearch.core.ReleasableIterator<LongBlock> lookup(IntBlock positions, ByteSizeValue targetBlockSize) Description copied from interface:VectorBuilds an Iterator of newBlocks with the sameVector.elementType()as thisVectorwhose values are copied from positions in this Vector. It has the same number ofpositionsas thepositionsparameter.For example, if this vector contained
[a, b, c]and were called with the block[0, 1, 1, [1, 2]]then the result would be[a, b, b, [b, c]].This process produces
count(positions)values per positions which could be quite large. Instead of returning a single Block, this returns an Iterator of Blocks containing all of the promised values.The returned
ReleasableIteratormay retain a reference to thepositionsparameter. Close it to release those references.This block is built using the same
BlockFactoryas was used to build thepositionsparameter.- Specified by:
lookupin interfaceLongVector- Specified by:
lookupin interfaceVector
-
slice
Description copied from interface:LongVectorReturn a subset of this vector frombeginInclusivetoendExclusive. This may return the same instance if the range covers all positions, but if it does it willRefCounted.incRef()it.- Specified by:
slicein interfaceLongVector- Specified by:
slicein interfaceVector
-