lapisx.sort
Class SortableArray
java.lang.Object
lapisx.sort.SortableArray
- All Implemented Interfaces:
- Sortable
- public class SortableArray
- extends Object
- implements Sortable
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
array
protected Object[] array
n
protected int n
SortableArray
public SortableArray(Object[] array)
SortableArray
public SortableArray(Object[] array,
int n)
get
public Object get(int i)
- Specified by:
get
in interface Sortable
set
public void set(int i,
Object o)
- Specified by:
set
in interface Sortable
size
public int size()
- Specified by:
size
in interface Sortable
swap
public void swap(int i,
int j)
- Specified by:
swap
in interface Sortable
compare
public int compare(Object o1,
Object o2)
- Specified by:
compare
in interface Sortable