|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.util.Vector
|
+--net.rim.device.api.util.SimpleSortingVector
Simple sorting vector of objects.
| Field Summary |
| Fields inherited from class java.util.Vector |
capacityIncrement, elementCount, elementData |
| Constructor Summary | ||
SimpleSortingVector()
Constructs a new SimpleSortingVector instance. |
||
| Method Summary | ||
void |
add(Object obj)
Deprecated. Use addElement(java.lang.Object) instead. |
|
void |
addElement(Object obj)
Adds provided object to this vector. |
|
int |
find(Object key)
Find an object in the vector based on a given key. |
|
Object |
getAt(int index)
Deprecated. Use Vector.elementAt(int) instead. |
|
Vector |
getVector()
Deprecated. SimpleSortingVector is now an instance of Vector |
|
void |
remove(int index)
Deprecated. Use Vector.removeElementAt(int) instead. |
|
void |
removeAll()
Deprecated. Use Vector.removeAllElements() instead. |
|
void |
reSort()
Sorts this vector. |
|
boolean |
setSort(boolean toSort)
Specifies whether this vector should sort dynamically. |
|
void |
setSortComparator(Comparator newComparator)
Sets a new comparator for use with this sorting vector. |
|
| Methods inherited from class java.util.Vector |
capacity, contains, copyInto, elementAt, elements, ensureCapacity, firstElement, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, removeAllElements, removeElement, removeElementAt, setElementAt, setSize, size, toString, trimToSize |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
| Method Detail |
public void add(Object obj)
addElement(java.lang.Object) instead.
If this vector was set to sort dynamically, then this vector sorts itself after the addition.
obj - Object to add.public void addElement(Object obj)
If this vector was set to sort dynamically, then this vector sorts itself after the addition.
addElement in class Vectorobj - Object to add.IllegalStateException - If a Comparator has not been set or is null.public int find(Object key)
key - Key to look for in the vector.-(insertionPoint + 1) is returned.IllegalStateException - If a Comparator has not been set or is null.public Object getAt(int index)
Vector.elementAt(int) instead.
index - Index of element of retrieve.public Vector getVector()
Invoke this method to retrieve this sorting vector's contents in Vector object.
public void remove(int index)
Vector.removeElementAt(int) instead.
index - Index of element to remove from this vector.public void removeAll()
Vector.removeAllElements() instead.
This method removes all elements from the vector.
public void reSort()
IllegalStateException - If a Comparator has not been set or is null.public boolean setSort(boolean toSort)
toSort - If true, this vector sorts as new elements are added, or
when a new comparator is specified; if false, then you must manually
invoke reSort() to sort this vector.IllegalStateException - If a Comparator has not been set or is null.public void setSortComparator(Comparator newComparator)
If this vector is currently set to be sorted as elements are added, then this method also sorts the vector.
newComparator - New comparator to use when sorting this vector.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2007 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.