Interface NaiveSortMaker
-
- All Known Implementing Classes:
DefaultNaiveSortMaker
public interface NaiveSortMaker
A NaiveSorter sorts a stream of data in-place. In the worst case, that means it needs to buffer up all RowsAndColumns received before it can return anything. This semantic interface is setup to allow an implementation of RowsAndColumns to know that it is pre-sorted and potentially return sorted data early.The default implementation cannot actually do this, however, so it is up to the specific concrete RowsAndColumns classes to provide their own implementations that can do this.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
NaiveSortMaker.NaiveSorter
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description static NaiveSortMaker
fromRAC(RowsAndColumns rac)
NaiveSortMaker.NaiveSorter
make(ArrayList<ColumnWithDirection> ordering)
Makes the NaiveSorter that will actually do the sort.default NaiveSortMaker.NaiveSorter
make(ColumnWithDirection... ordering)
-
-
-
Method Detail
-
fromRAC
static NaiveSortMaker fromRAC(RowsAndColumns rac)
-
make
NaiveSortMaker.NaiveSorter make(ArrayList<ColumnWithDirection> ordering)
Makes the NaiveSorter that will actually do the sort.- Parameters:
ordering
- a specification of which columns to sort in which direction- Returns:
- a NaiveSorter that will sort according to the provided spec
-
make
default NaiveSortMaker.NaiveSorter make(ColumnWithDirection... ordering)
-
-