|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.util.AbstractCollection
|
+--java.util.AbstractList
|
+--java.util.ArrayList
|
+--com.ds.fw.types.collections.FwList
This class is a subclass of the ArrayList class. It implements the FwListIF interface which adds some convenient methodsbut does not add any new core functionality to the ArrayList.
| Field Summary |
| Fields inherited from class java.util.AbstractList |
modCount |
| Constructor Summary | |
FwList()
Default constructor method. |
|
FwList(java.util.Collection c)
Constructor. |
|
FwList(java.util.Iterator i)
Constructor. |
|
| Method Summary | |
void |
addAll(java.util.Iterator i)
Adds to the list the collection the given iterator points. |
boolean |
addAssociation(java.lang.Object key,
java.lang.Object value)
Adds an association object to the list. |
boolean |
addInt(int value)
Adds an int value to the list. |
boolean |
containsInt(int value)
Checks if the list contains a value. |
com.ds.fw.types.collections.FwCursorIteratorIF |
cursorIterator()
Gets a FwCursorIterator for the list. |
com.ds.fw.types.FwCodeIF |
findCode(java.lang.String s)
Finds an element of the list with the given code s. |
com.ds.fw.types.FwIdIF |
findId(java.lang.String s)
Finds an element of the list with the given id s. |
java.lang.String |
getClassName()
Returns the class name of the current instance. |
java.lang.Object |
getClone()
Clones the list. |
java.lang.Object |
getCopy()
Clones the list. |
java.lang.Object |
getCopy(java.lang.Object e)
Clones the object e. |
java.lang.Object |
getDeepCopy()
Copies the list. |
java.lang.String |
getDisplayString()
Returns the class name and the size of the list. |
java.lang.String |
getDisplayStringFor(java.lang.Object e)
Gets the String representstion of the object e. |
java.lang.Object |
getFirst()
Gets the first element of the list. |
java.lang.String |
getFullDisplayString()
Returns a String representation of the list content. |
int |
getIntAt(int index)
Gets the int value with index index. |
java.lang.Object |
getLast()
Gets the last element of the list. |
java.lang.String |
getString(int i)
Gets the element at position i and casts it to String. |
boolean |
hasCode(java.lang.String s)
Checks if the list contains element with the given code. |
boolean |
hasId(java.lang.String s)
Checks if the list contains element with the given id. |
java.util.Iterator |
iterator()
Gets an Iterator for the list. |
java.util.ListIterator |
listIterator()
Gets a ListIterator for the list. |
boolean |
matches(java.util.Collection c)
Compares the current list with the given collection c |
void |
postCopy()
Copies elements content. |
void |
removeDuplicateInstances()
Removes duplicated elements from the list. |
boolean |
removeInt(int value)
Removes the value from the list. |
boolean |
reorderIds(java.util.List ids)
Reorders the list by the order of the IDs in the given list ids. |
void |
replaceAll(java.util.Collection c)
Replaces the list content with that of the given collection. |
void |
replaceAll(java.util.Iterator i)
Replaces the list content with that the given iterator points. |
void |
reverse()
Reverses the order of the list elements. |
java.util.Iterator |
reverseIterator()
Gets an Iterator for the list, which works backward, the opposite of the standart Iterator. |
void |
setIntAt(int index,
int value)
Sets an int value at position index |
void |
shuffle()
Shuffles the list. |
void |
sort()
Sorts the list. |
void |
sort(java.util.Comparator c)
Sorts the list using the given comparator. |
java.lang.String |
toString()
Returns the class name and the size of the list. |
java.lang.String |
toStringValue()
Returns the size of the list. |
| Methods inherited from class java.util.ArrayList |
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, removeRange, set, size, toArray, toArray, trimToSize |
| Methods inherited from class java.util.AbstractList |
equals, hashCode, listIterator, subList |
| Methods inherited from class java.util.AbstractCollection |
containsAll, remove, removeAll, retainAll |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, lastIndexOf, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray |
| Constructor Detail |
public FwList()
public FwList(java.util.Collection c)
c - a collection objectpublic FwList(java.util.Iterator i)
i - an iterator object| Method Detail |
public java.lang.String getString(int i)
getString in interface FwListIFi - an element's index
java.lang.IndexOutOfBoundsException - if i is not in the array boundspublic java.lang.Object getCopy()
getCopy in interface FwListIFFwFatalException - if could not cloneFwCopyableIFpublic java.lang.Object getCopy(java.lang.Object e)
getCopy in interface FwCopyableIFUsupportedOperationException - the object does not implements FwCopyableIF interface.public java.lang.Object getDeepCopy()
getDeepCopy in interface FwListIFFwCopyableIFpublic void postCopy()
postCopy in interface FwCopyableIFpublic java.lang.Object getClone()
getClone in interface FwCopyableIFFwFatalException - if could not clonepublic java.lang.String toString()
toString in interface FwDisplayableIFtoString in class java.util.AbstractCollectionpublic java.lang.String toStringValue()
toStringValue in interface FwDisplayableIFpublic java.lang.String getDisplayString()
getDisplayString in interface FwDisplayableIFpublic java.lang.String getDisplayStringFor(java.lang.Object e)
getDisplayStringFor in interface FwDisplayableIFpublic java.lang.String getClassName()
getClassName in interface FwDisplayableIFpublic java.lang.String getFullDisplayString()
getFullDisplayString in interface FwListIFpublic java.util.Iterator iterator()
iterator in interface java.util.Listiterator in class java.util.AbstractListpublic java.util.ListIterator listIterator()
listIterator in interface java.util.ListlistIterator in class java.util.AbstractListpublic com.ds.fw.types.collections.FwCursorIteratorIF cursorIterator()
cursorIterator in interface FwListIFpublic java.util.Iterator reverseIterator()
reverseIterator in interface FwListIFpublic java.lang.Object getFirst()
getFirst in interface FwListIFpublic java.lang.Object getLast()
getLast in interface FwListIFpublic com.ds.fw.types.FwIdIF findId(java.lang.String s)
findId in interface FwListIFs - the id to search for
public com.ds.fw.types.FwCodeIF findCode(java.lang.String s)
findCode in interface FwListIFs - the code to search for
public boolean hasId(java.lang.String s)
hasId in interface FwListIFs - the id to search for
findId(String)public boolean hasCode(java.lang.String s)
hasCode in interface FwListIFs - the code to search for
findCode(String)public boolean matches(java.util.Collection c)
matches in interface FwListIFpublic boolean addInt(int value)
addInt in interface FwListIFvalue - the value to be added
public boolean removeInt(int value)
removeInt in interface FwListIFvalue - the value to be removed
public boolean containsInt(int value)
containsInt in interface FwListIFvalue - the value to be searched
public int getIntAt(int index)
getIntAt in interface FwListIFindex - the index
public void setIntAt(int index,
int value)
setIntAt in interface FwListIFindex - the positionvalue - the value
public boolean addAssociation(java.lang.Object key,
java.lang.Object value)
addAssociation in interface FwListIFkey - object's keyvalue - object's value
public void reverse()
reverse in interface FwListIFpublic void replaceAll(java.util.Collection c)
replaceAll in interface FwListIFc - the collection which content replaces the current list contentreplaceAll(Iterator)public void replaceAll(java.util.Iterator i)
replaceAll in interface FwListIFi - the iteratorpublic void addAll(java.util.Iterator i)
addAll in interface FwListIFi - the iteratorpublic void sort()
sort in interface FwListIFpublic void sort(java.util.Comparator c)
sort in interface FwListIFc - the comparatorpublic boolean reorderIds(java.util.List ids)
reorderIds in interface FwListIFids - list with new ID order
public void shuffle()
shuffle in interface FwListIFpublic void removeDuplicateInstances()
removeDuplicateInstances in interface FwListIF
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||