Package dsa.lab04.base
Interface Sorter
- All Known Implementing Classes:
- HeapSorter,- HeapSorter,- InsertionSorter,- InsertionSorter,- MergeSorter,- MergeSorter,- SelectionSorter,- SelectionSorter
public interface Sorter
A sorting algorithm.
- 
Method SummaryModifier and TypeMethodDescriptiondefault <Item extends Comparable<Item>>
 voidsort(StaticSequence<Item> items) Sorts the given sequence.<Item> voidsort(StaticSequence<Item> items, Comparator<Item> comparator) Sorts the given sequence according to the given comparator.
- 
Method Details- 
sortSorts the given sequence according to the given comparator.- Type Parameters:
- Item- the item type
- Parameters:
- items- the items to sort
- comparator- how to compare the items
 
- 
sortSorts the given sequence.- Type Parameters:
- Item- the item type
- Parameters:
- items- the items to sort
 
 
-