Package io.deephaven.function
Class Sort
java.lang.Object
io.deephaven.function.Sort
Functions for sorting primitive types.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic int[]
rank
(byte... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(double... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(float... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(int... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(long... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(short... values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(ByteVector values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(DoubleVector values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(FloatVector values) Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
rank
(LongVector values) Returns the indices of values sorted from smallest to largest.static int[]
rank
(ShortVector values) Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
Returns the indices of values sorted from smallest to largest.static int[]
rankDescending
(byte... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(double... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(float... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(int... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(long... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(short... values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(ByteVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(DoubleVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(FloatVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(IntVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(LongVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(ShortVector values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Byte[] values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Double[] values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Float[] values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Integer[] values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Long[] values) Returns the indices of values sorted from largest to smallest.static int[]
rankDescending
(Short[] values) Returns the indices of values sorted from largest to smallest.static <T extends Comparable<? super T>>
int[]rankDescendingObj
(ObjectVector<T> values) Returns the indices of values sorted from largest to smallest.static <T extends Comparable<? super T>>
int[]rankDescendingObj
(ObjectVector<T> values, Comparator<T> comparator) Returns the indices of values sorted from largest to smallest.static <T extends Comparable<? super T>>
int[]rankDescendingObj
(T... values) Returns the indices of values sorted from largest to smallest.static <T extends Comparable<? super T>>
int[]rankDescendingObj
(T[] values, Comparator<T> comparator) Returns the indices of values sorted from largest to smallest.static <T extends Comparable<? super T>>
int[]rankObj
(ObjectVector<T> values) Returns the indices of values sorted from smallest to largest.static <T extends Comparable<? super T>>
int[]rankObj
(ObjectVector<T> values, Comparator<T> comparator) Returns the indices of values sorted from smallest to largest.static <T extends Comparable<? super T>>
int[]rankObj
(T... values) Returns the indices of values sorted from smallest to largest.static <T extends Comparable<? super T>>
int[]rankObj
(T[] values, Comparator<T> comparator) Returns the indices of values sorted from smallest to largest.static byte[]
sort
(byte... values) Returns sorted values from smallest to largest.static double[]
sort
(double... values) Returns sorted values from smallest to largest.static float[]
sort
(float... values) Returns sorted values from smallest to largest.static int[]
sort
(int... values) Returns sorted values from smallest to largest.static long[]
sort
(long... values) Returns sorted values from smallest to largest.static short[]
sort
(short... values) Returns sorted values from smallest to largest.static byte[]
sort
(ByteVector values) Returns sorted values from smallest to largest.static double[]
sort
(DoubleVector values) Returns sorted values from smallest to largest.static float[]
sort
(FloatVector values) Returns sorted values from smallest to largest.static int[]
Returns sorted values from smallest to largest.static long[]
sort
(LongVector values) Returns sorted values from smallest to largest.static short[]
sort
(ShortVector values) Returns sorted values from smallest to largest.static byte[]
Returns sorted values from smallest to largest.static double[]
Returns sorted values from smallest to largest.static float[]
Returns sorted values from smallest to largest.static int[]
Returns sorted values from smallest to largest.static long[]
Returns sorted values from smallest to largest.static short[]
Returns sorted values from smallest to largest.static byte[]
sortDescending
(byte... values) Returns sorted values from largest to smallest.static double[]
sortDescending
(double... values) Returns sorted values from largest to smallest.static float[]
sortDescending
(float... values) Returns sorted values from largest to smallest.static int[]
sortDescending
(int... values) Returns sorted values from largest to smallest.static long[]
sortDescending
(long... values) Returns sorted values from largest to smallest.static short[]
sortDescending
(short... values) Returns sorted values from largest to smallest.static byte[]
sortDescending
(ByteVector values) Returns sorted values from largest to smallest.static double[]
sortDescending
(DoubleVector values) Returns sorted values from largest to smallest.static float[]
sortDescending
(FloatVector values) Returns sorted values from largest to smallest.static int[]
sortDescending
(IntVector values) Returns sorted values from largest to smallest.static long[]
sortDescending
(LongVector values) Returns sorted values from largest to smallest.static short[]
sortDescending
(ShortVector values) Returns sorted values from largest to smallest.static byte[]
sortDescending
(Byte[] values) Returns sorted values from largest to smallest.static double[]
sortDescending
(Double[] values) Returns sorted values from largest to smallest.static float[]
sortDescending
(Float[] values) Returns sorted values from largest to smallest.static int[]
sortDescending
(Integer[] values) Returns sorted values from largest to smallest.static long[]
sortDescending
(Long[] values) Returns sorted values from largest to smallest.static short[]
sortDescending
(Short[] values) Returns sorted values from largest to smallest.static <T extends Comparable<? super T>>
T[]sortDescendingObj
(ObjectVector<T> values) Returns sorted values from largest to smallest.static <T extends Comparable<? super T>>
T[]sortDescendingObj
(ObjectVector<T> values, Comparator<T> comparator) Returns sorted values from largest to smallest.static <T extends Comparable<? super T>>
T[]sortDescendingObj
(T... values) Returns sorted values from largest to smallest.static <T extends Comparable<? super T>>
T[]sortDescendingObj
(T[] values, Comparator<T> comparator) Returns sorted values from largest to smallest.static <T extends Comparable<? super T>>
T[]sortObj
(ObjectVector<T> values) Returns sorted values from smallest to largest.static <T extends Comparable<? super T>>
T[]sortObj
(ObjectVector<T> values, Comparator<T> comparator) Returns sorted values from smallest to largest.static <T extends Comparable<? super T>>
T[]sortObj
(T... values) Returns sorted values from smallest to largest.static <T extends Comparable<? super T>>
T[]sortObj
(T[] values, Comparator<T> comparator) Returns sorted values from smallest to largest.
-
Constructor Details
-
Sort
public Sort()
-
-
Method Details
-
sortObj
public static <T extends Comparable<? super T>> T[] sortObj(ObjectVector<T> values, Comparator<T> comparator) Returns sorted values from smallest to largest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted values.
-
sortObj
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortObj
Returns sorted values from smallest to largest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted values.
-
sortObj
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankObj
public static <T extends Comparable<? super T>> int[] rankObj(ObjectVector<T> values, Comparator<T> comparator) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted indices.
-
rankObj
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankObj
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted indices.
-
rankObj
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescendingObj
public static <T extends Comparable<? super T>> T[] sortDescendingObj(ObjectVector<T> values, Comparator<T> comparator) Returns sorted values from largest to smallest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted values.
-
sortDescendingObj
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescendingObj
public static <T extends Comparable<? super T>> T[] sortDescendingObj(T[] values, Comparator<T> comparator) Returns sorted values from largest to smallest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted values.
-
sortDescendingObj
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescendingObj
public static <T extends Comparable<? super T>> int[] rankDescendingObj(ObjectVector<T> values, Comparator<T> comparator) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted indices.
-
rankDescendingObj
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescendingObj
public static <T extends Comparable<? super T>> int[] rankDescendingObj(T[] values, Comparator<T> comparator) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.comparator
- value comparator.- Returns:
- sorted indices.
-
rankDescendingObj
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static byte[] sort(byte... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(byte... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static byte[] sortDescending(byte... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(byte... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static short[] sort(short... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(short... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static short[] sortDescending(short... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(short... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static int[] sort(int... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(int... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static int[] sortDescending(int... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(int... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static long[] sort(long... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(long... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static long[] sortDescending(long... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(long... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static float[] sort(float... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(float... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static float[] sortDescending(float... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(float... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
public static double[] sort(double... values) Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sort
Returns sorted values from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
public static int[] rank(double... values) Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rank
Returns the indices of values sorted from smallest to largest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
public static double[] sortDescending(double... values) Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
sortDescending
Returns sorted values from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted values.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
public static int[] rankDescending(double... values) Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-
rankDescending
Returns the indices of values sorted from largest to smallest.- Parameters:
values
- values.- Returns:
- sorted indices.
-