@NotThreadSafe public class SortBasedDataBuffer extends SortBuffer
SortBasedDataBuffer
should recycle the read target buffer with
the given BufferRecycler
.bufferRecycler, freeSegments, INDEX_ENTRY_SIZE, isFinished, isReleased, lastIndexEntryAddresses, numTotalBytesRead, readIndexEntryAddress, readOrderIndex, recordRemainingBytes, segments, subpartitionReadOrder
Constructor and Description |
---|
SortBasedDataBuffer(LinkedList<MemorySegment> freeSegments,
BufferRecycler bufferRecycler,
int numSubpartitions,
int bufferSize,
int numGuaranteedBuffers,
int[] customReadOrder) |
Modifier and Type | Method and Description |
---|---|
BufferWithChannel |
getNextBuffer(MemorySegment transitBuffer)
Copies data in this
DataBuffer to the target MemorySegment in channel index
order and returns BufferWithChannel which contains the copied data and the
corresponding channel index. |
append, copyRecordOrEvent, finish, getSegmentIndexFromPointer, getSegmentOffsetFromPointer, hasRemaining, isFinished, isReleased, numTotalBytes, numTotalRecords, release, updateReadChannelAndIndexEntryAddress
public SortBasedDataBuffer(LinkedList<MemorySegment> freeSegments, BufferRecycler bufferRecycler, int numSubpartitions, int bufferSize, int numGuaranteedBuffers, @Nullable int[] customReadOrder)
public BufferWithChannel getNextBuffer(MemorySegment transitBuffer)
DataBuffer
DataBuffer
to the target MemorySegment
in channel index
order and returns BufferWithChannel
which contains the copied data and the
corresponding channel index.Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.