Package org.apache.lucene.util
Class InPlaceMergeSorter
- java.lang.Object
-
- org.apache.lucene.util.Sorter
-
- org.apache.lucene.util.InPlaceMergeSorter
-
- Direct Known Subclasses:
ArrayInPlaceMergeSorter
,WordDelimiterFilter.OffsetSorter
,WordDelimiterGraphFilter.PositionSorter
public abstract class InPlaceMergeSorter extends Sorter
Sorter
implementation based on the merge-sort algorithm that merges in place (no extra memory will be allocated). Small arrays are sorted with insertion sort.
-
-
Field Summary
-
Fields inherited from class org.apache.lucene.util.Sorter
BINARY_SORT_THRESHOLD
-
-
Constructor Summary
Constructors Constructor Description InPlaceMergeSorter()
Create a newInPlaceMergeSorter
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
mergeSort(int from, int to)
void
sort(int from, int to)
Sort the slice which starts atfrom
(inclusive) and ends atto
(exclusive).-
Methods inherited from class org.apache.lucene.util.Sorter
binarySort, binarySort, checkRange, compare, comparePivot, doRotate, heapChild, heapify, heapParent, heapSort, lower, lower2, mergeInPlace, reverse, rotate, setPivot, siftDown, swap, upper, upper2
-
-
-
-
Constructor Detail
-
InPlaceMergeSorter
public InPlaceMergeSorter()
Create a newInPlaceMergeSorter
-
-