|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdsto.dfc.collections.DfcCollections
public final class DfcCollections
Miscellaneous utilities for use with the Java Collections classes.
| Method Summary | |
|---|---|
static boolean |
arraysEqual(int[] a1,
int[] a2)
Test whether two int arrays are equal. |
static boolean |
arraysEqual(Object[] a1,
Object[] a2)
|
static int |
compareArrays(Object[] a1,
Object[] a2)
Compare the contents of two arrays. |
static boolean |
containsAny(Collection source,
Collection coll)
Test if one collection contains any element from another. |
static boolean |
containsAny(Collection source,
Collection coll,
Comparator comparator)
Test if one collection contains any element from another. |
static int |
findSortedIndex(List items,
Object item)
Find the index that an item should have in a sorted list to maintain the sorted order. |
static int |
findSortedIndex(List items,
Object item,
Comparator comparator)
Find the index that an item should have in a sorted list to maintain the sorted order. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static int findSortedIndex(List items,
Object item)
items - A sorted list of items.item - The item.
public static int findSortedIndex(List items,
Object item,
Comparator comparator)
items - A sorted list of items.item - The item.comparator - The comparator used to order the list.
public static int compareArrays(Object[] a1,
Object[] a2)
throws IllegalArgumentException
a1 - The first array.a2 - The second array.
IllegalArgumentException - if any of the elements in a1 or a2 are
found not to be Comparable.
public static boolean arraysEqual(int[] a1,
int[] a2)
public static boolean arraysEqual(Object[] a1,
Object[] a2)
public static boolean containsAny(Collection source,
Collection coll)
containsAny(Collection, Collection, Comparator)
public static boolean containsAny(Collection source,
Collection coll,
Comparator comparator)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||