Class BaseIntUpdateByOperator.Context
java.lang.Object
io.deephaven.engine.table.impl.updateby.UpdateByOperator.Context
io.deephaven.engine.table.impl.updateby.internal.BaseIntUpdateByOperator.Context
- All Implemented Interfaces:
SafeCloseable
,AutoCloseable
- Direct Known Subclasses:
IntCumMinMaxOperator.Context
,IntDeltaOperator.Context
,IntFillByOperator.Context
,IntRollingMinMaxOperator.Context
- Enclosing class:
- BaseIntUpdateByOperator
-
Field Summary
FieldsModifier and TypeFieldDescriptionint
protected final ChunkSink.FillFromContext
protected final WritableIntChunk<Values>
Fields inherited from class io.deephaven.engine.table.impl.updateby.UpdateByOperator.Context
affectedPosChunk, influencerPosChunk, nullCount
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
accumulateCumulative
(@NotNull RowSequence inputKeys, @NotNull Chunk<? extends Values>[] valueChunkArr, @Nullable LongChunk<? extends Values> tsChunk, int len) For cumulative operators only, this method will be called to pass the input chunk data to the operator and produce the output data values.void
accumulateRolling
(@NotNull RowSequence inputKeys, @NotNull Chunk<? extends Values>[] influencerValueChunkArr, @Nullable LongChunk<OrderedRowKeys> affectedPosChunk, @Nullable LongChunk<OrderedRowKeys> influencerPosChunk, @NotNull IntChunk<? extends Values> pushChunk, @NotNull IntChunk<? extends Values> popChunk, int affectedCount, int influencerCount) For windowed operators only, this method will be called to pass the input chunk data to the operator and produce the output data values.void
close()
void
reset()
Reset the operator data values to a known state.void
setValueChunks
(@NotNull Chunk<? extends Values>[] valueChunks) protected void
writeNullToOutputChunk
(int outIdx) void
writeToOutputChunk
(int outIdx) Write the current value for this row to the output chunkvoid
writeToOutputColumn
(@NotNull RowSequence inputKeys) Write the output chunk to the output columnMethods inherited from class io.deephaven.engine.table.impl.updateby.UpdateByOperator.Context
isValueValid, pop, push, setPosChunks
-
Field Details
-
outputFillContext
-
outputValues
-
curVal
public int curVal
-
-
Constructor Details
-
Context
protected Context(int chunkSize)
-
-
Method Details
-
accumulateCumulative
public void accumulateCumulative(@NotNull @NotNull RowSequence inputKeys, @NotNull @NotNull Chunk<? extends Values>[] valueChunkArr, @Nullable @Nullable LongChunk<? extends Values> tsChunk, int len) Description copied from class:UpdateByOperator.Context
For cumulative operators only, this method will be called to pass the input chunk data to the operator and produce the output data values.- Specified by:
accumulateCumulative
in classUpdateByOperator.Context
- Parameters:
inputKeys
- the keys for the input data rows (also matches the output keys)valueChunkArr
- the input data chunks needed by the operator for internal calculationstsChunk
- the timestamp chunk for the input data (if applicable)len
- the number of items in the input data chunks
-
accumulateRolling
public void accumulateRolling(@NotNull @NotNull RowSequence inputKeys, @NotNull @NotNull Chunk<? extends Values>[] influencerValueChunkArr, @Nullable @Nullable LongChunk<OrderedRowKeys> affectedPosChunk, @Nullable @Nullable LongChunk<OrderedRowKeys> influencerPosChunk, @NotNull @NotNull IntChunk<? extends Values> pushChunk, @NotNull @NotNull IntChunk<? extends Values> popChunk, int affectedCount, int influencerCount) Description copied from class:UpdateByOperator.Context
For windowed operators only, this method will be called to pass the input chunk data to the operator and produce the output data values. It is important to note that the size of the influencer (input) and affected (output) chunks are not likely be the same. We pass these sizes explicitly to the operators for the sake of the operators (such asCountWhereOperator
with zero input columns) where no input chunks are provided but we must still process the exact number of input rows.- Specified by:
accumulateRolling
in classUpdateByOperator.Context
- Parameters:
inputKeys
- the keys for the input data rows (also matches the output keys)influencerValueChunkArr
- the input data chunks needed by the operator for internal calculations, these values will be pushed and popped into the current windowaffectedPosChunk
- the row positions of the affected rowsinfluencerPosChunk
- the row positions of the influencer rowspushChunk
- a chunk containing the push instructions for each output row to be calculatedpopChunk
- a chunk containing the pop instructions for each output row to be calculatedaffectedCount
- how many affected (output) rows are being computedinfluencerCount
- how many influencer (input) rows are needed for the computation
-
setValueChunks
- Specified by:
setValueChunks
in classUpdateByOperator.Context
-
writeToOutputChunk
public void writeToOutputChunk(int outIdx) Description copied from class:UpdateByOperator.Context
Write the current value for this row to the output chunk- Specified by:
writeToOutputChunk
in classUpdateByOperator.Context
-
writeNullToOutputChunk
protected void writeNullToOutputChunk(int outIdx) -
writeToOutputColumn
Description copied from class:UpdateByOperator.Context
Write the output chunk to the output column- Specified by:
writeToOutputColumn
in classUpdateByOperator.Context
-
reset
public void reset()Description copied from class:UpdateByOperator.Context
Reset the operator data values to a known state. This may occur during initialization or when a windowed operator has an empty window- Specified by:
reset
in classUpdateByOperator.Context
-
close
public void close()
-