Class SortUtil
- java.lang.Object
-
- org.apache.flink.table.runtime.operators.sort.SortUtil
-
public class SortUtil extends Object
Util for sort.
-
-
Constructor Summary
Constructors Constructor Description SortUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
compareBinary(byte[] a, byte[] b)
static int
compareBinary(byte[] buffer1, int offset1, int length1, byte[] buffer2, int offset2, int length2)
static void
maxNormalizedKey(MemorySegment target, int offset, int numBytes)
Max unsigned byte is -1.static void
minNormalizedKey(MemorySegment target, int offset, int numBytes)
static void
putBinaryNormalizedKey(byte[] value, MemorySegment target, int offset, int numBytes)
static void
putBooleanNormalizedKey(boolean value, MemorySegment target, int offset, int numBytes)
static void
putByteNormalizedKey(byte value, MemorySegment target, int offset, int numBytes)
static void
putDecimalNormalizedKey(DecimalData record, MemorySegment target, int offset, int len)
Just support the compact precision decimal.static void
putDoubleNormalizedKey(double value, MemorySegment target, int offset, int numBytes)
See http://stereopsis.com/radix.html for more details.static void
putFloatNormalizedKey(float value, MemorySegment target, int offset, int numBytes)
See http://stereopsis.com/radix.html for more details.static void
putIntNormalizedKey(int value, MemorySegment target, int offset, int numBytes)
static void
putLongNormalizedKey(long value, MemorySegment target, int offset, int numBytes)
static void
putShortNormalizedKey(short value, MemorySegment target, int offset, int numBytes)
static void
putStringNormalizedKey(StringData value, MemorySegment target, int offset, int numBytes)
UTF-8 supports bytes comparison.static void
putTimestampNormalizedKey(TimestampData value, MemorySegment target, int offset, int numBytes)
Support the compact precision TimestampData.
-
-
-
Method Detail
-
minNormalizedKey
public static void minNormalizedKey(MemorySegment target, int offset, int numBytes)
-
maxNormalizedKey
public static void maxNormalizedKey(MemorySegment target, int offset, int numBytes)
Max unsigned byte is -1.
-
putShortNormalizedKey
public static void putShortNormalizedKey(short value, MemorySegment target, int offset, int numBytes)
-
putByteNormalizedKey
public static void putByteNormalizedKey(byte value, MemorySegment target, int offset, int numBytes)
-
putBooleanNormalizedKey
public static void putBooleanNormalizedKey(boolean value, MemorySegment target, int offset, int numBytes)
-
putStringNormalizedKey
public static void putStringNormalizedKey(StringData value, MemorySegment target, int offset, int numBytes)
UTF-8 supports bytes comparison.
-
putDecimalNormalizedKey
public static void putDecimalNormalizedKey(DecimalData record, MemorySegment target, int offset, int len)
Just support the compact precision decimal.
-
putIntNormalizedKey
public static void putIntNormalizedKey(int value, MemorySegment target, int offset, int numBytes)
-
putLongNormalizedKey
public static void putLongNormalizedKey(long value, MemorySegment target, int offset, int numBytes)
-
putFloatNormalizedKey
public static void putFloatNormalizedKey(float value, MemorySegment target, int offset, int numBytes)
See http://stereopsis.com/radix.html for more details.
-
putDoubleNormalizedKey
public static void putDoubleNormalizedKey(double value, MemorySegment target, int offset, int numBytes)
See http://stereopsis.com/radix.html for more details.
-
putBinaryNormalizedKey
public static void putBinaryNormalizedKey(byte[] value, MemorySegment target, int offset, int numBytes)
-
putTimestampNormalizedKey
public static void putTimestampNormalizedKey(TimestampData value, MemorySegment target, int offset, int numBytes)
Support the compact precision TimestampData.
-
compareBinary
public static int compareBinary(byte[] a, byte[] b)
-
compareBinary
public static int compareBinary(byte[] buffer1, int offset1, int length1, byte[] buffer2, int offset2, int length2)
-
-