IndexedSorter@Private @Unstable public final class QuickSort extends java.lang.Object implements IndexedSorter
| Constructor | Description |
|---|---|
QuickSort() |
| Modifier and Type | Method | Description |
|---|---|---|
protected static int |
getMaxDepth(int x) |
Deepest recursion before giving up and doing a heapsort.
|
void |
sort(IndexedSortable s,
int p,
int r) |
Sort the given range of items using quick sort.
|
void |
sort(IndexedSortable s,
int p,
int r,
Progressable rep) |
Same as
IndexedSorter.sort(IndexedSortable,int,int), but indicate progress
periodically. |
protected static int getMaxDepth(int x)
x - x.public void sort(IndexedSortable s, int p, int r)
getMaxDepth(int),
then switch to HeapSort.sort in interface IndexedSorters - s.p - l.r - r.IndexedSortable.compare(int, int),
IndexedSortable.swap(int, int)public void sort(IndexedSortable s, int p, int r, Progressable rep)
IndexedSorterIndexedSorter.sort(IndexedSortable,int,int), but indicate progress
periodically.sort in interface IndexedSorters - s.p - l.r - r.rep - rep.IndexedSorter.sort(IndexedSortable,int,int)Copyright © 2008–2025 Apache Software Foundation. All rights reserved.