Class BinarySection
- java.lang.Object
-
- org.apache.flink.table.data.binary.BinarySection
-
- All Implemented Interfaces:
BinaryFormat
- Direct Known Subclasses:
BinaryArrayData
,BinaryMapData
,BinaryRowData
,NestedRowData
@Internal public class BinarySection extends Object implements BinaryFormat
A basic implementation ofBinaryFormat
which describe a section of memory.
-
-
Field Summary
Fields Modifier and Type Field Description protected int
offset
protected MemorySegment[]
segments
protected int
sizeInBytes
-
Fields inherited from interface org.apache.flink.table.data.binary.BinaryFormat
HIGHEST_FIRST_BIT, HIGHEST_SECOND_TO_EIGHTH_BIT, MAX_FIX_PART_DATA_SIZE
-
-
Constructor Summary
Constructors Constructor Description BinarySection()
BinarySection(MemorySegment[] segments, int offset, int sizeInBytes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object o)
int
getOffset()
Gets the start offset of this binary data in theMemorySegment
s.MemorySegment[]
getSegments()
Gets the underlyingMemorySegment
s this binary format spans.int
getSizeInBytes()
Gets the size in bytes of this binary data.int
hashCode()
void
pointTo(MemorySegment[] segments, int offset, int sizeInBytes)
void
pointTo(MemorySegment segment, int offset, int sizeInBytes)
-
-
-
Field Detail
-
segments
protected MemorySegment[] segments
-
offset
protected int offset
-
sizeInBytes
protected int sizeInBytes
-
-
Constructor Detail
-
BinarySection
public BinarySection()
-
BinarySection
public BinarySection(MemorySegment[] segments, int offset, int sizeInBytes)
-
-
Method Detail
-
pointTo
public final void pointTo(MemorySegment segment, int offset, int sizeInBytes)
-
pointTo
public void pointTo(MemorySegment[] segments, int offset, int sizeInBytes)
-
getSegments
public MemorySegment[] getSegments()
Description copied from interface:BinaryFormat
Gets the underlyingMemorySegment
s this binary format spans.- Specified by:
getSegments
in interfaceBinaryFormat
-
getOffset
public int getOffset()
Description copied from interface:BinaryFormat
Gets the start offset of this binary data in theMemorySegment
s.- Specified by:
getOffset
in interfaceBinaryFormat
-
getSizeInBytes
public int getSizeInBytes()
Description copied from interface:BinaryFormat
Gets the size in bytes of this binary data.- Specified by:
getSizeInBytes
in interfaceBinaryFormat
-
-