/** * Perform a merge sort of the specific range of an array of objects that implement * Comparable. * @param <T> the type of the objects in the array. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void mergeSort(T[] array, int start, int end) { mergeSort(array, start, end, new ComparableAdaptor<T>()); }
/** * Perform a merge sort of the specific range of an array of objects that implement * Comparable. * @param <T> the type of the objects in the array. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void mergeSort(T[] array, int start, int end) { mergeSort(array, start, end, new ComparableAdaptor<T>()); }
/** * Sort the specified range of an array of object that implement the Comparable * interface. * @param <T> The type of object. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void quickSort(T[] array, int start, int end) { quickSort(array, start, end, new ComparableAdaptor<T>()); }
/** * Sort the specified range of an array of object that implement the Comparable * interface. * @param <T> The type of object. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void quickSort(T[] array, int start, int end) { quickSort(array, start, end, new ComparableAdaptor<T>()); }
/** * Perform a merge sort of the specific range of an array of objects that implement * Comparable. * @param <T> the type of the objects in the array. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void mergeSort(T[] array, int start, int end) { mergeSort(array, start, end, new ComparableAdaptor<T>()); }
/** * Sort the specified range of an array of object that implement the Comparable * interface. * @param <T> The type of object. * @param array the array. * @param start the first index. * @param end the last index (exclusive). */ public static <T extends Comparable<? super T>> void quickSort(T[] array, int start, int end) { quickSort(array, start, end, new ComparableAdaptor<T>()); }