|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.ArrayList<java.lang.Comparable>
de.uni_leipzig.bf.util.AlphaList
public class AlphaList
Implements an alphabetically sorted set. The retrieval of objects is binary and thus has a logarithmic worst case time complexity

| Field Summary |
|---|
| Fields inherited from class java.util.AbstractList |
|---|
modCount |
| Constructor Summary | |
|---|---|
AlphaList()
|
|
| Method Summary | |
|---|---|
boolean |
addd(java.lang.Comparable o)
add elements in alphabetic order |
boolean |
containss(java.lang.Comparable o)
|
int |
idxOf(java.lang.Comparable o)
Implements a binary search to find objects in the list. |
protected boolean |
insert(int index,
java.lang.Comparable o)
Insert an element at a given position |
| Methods inherited from class java.util.ArrayList |
|---|
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, set, size, toArray, toArray, trimToSize |
| Methods inherited from class java.util.AbstractList |
|---|
equals, hashCode, iterator, listIterator, listIterator, subList |
| Methods inherited from class java.util.AbstractCollection |
|---|
containsAll, removeAll, retainAll, toString |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList |
| Constructor Detail |
|---|
public AlphaList()
| Method Detail |
|---|
public boolean addd(java.lang.Comparable o)
o - The object to add
public boolean containss(java.lang.Comparable o)
public int idxOf(java.lang.Comparable o)
o - Object to look for
protected boolean insert(int index,
java.lang.Comparable o)
index - Position where the object is to be addedo - Ojbect to add
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||