|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--ix.util.Collect
Collection and Map utilities
Fn,
Strings,
Util| Method Summary | |
static java.util.Collection |
difference(java.util.Collection a,
java.util.Collection b)
Returns a new collection of the same class as its first argument and that contains the elements of the first collection that do not appear in the second. |
static java.util.List |
ensureList(java.util.List list)
Ensures that a value is a List object by returning an empty list if the value is null. |
static boolean |
equalAsSets(java.util.List a,
java.util.List b)
Determines whether two Lists have the same elements regardless of order. |
static java.util.Collection |
filter(java.lang.Class resultClass,
java.util.Collection c,
Predicate1 p)
Returns a new collection of the specified result class and and containing only the elements for which the predicate returned true; |
static java.util.Collection |
filter(java.util.Collection c,
Predicate1 p)
Returns a new collection of the same class as the original and containing only the elements for which the predicate returned true; |
static java.util.Collection |
intersection(java.util.Collection a,
java.util.Collection b)
Returns a new collection of the same class as its first argument and that contains the elements that appear in both collections. |
static boolean |
isEmpty(java.util.Collection c)
Returns true iff the collection is either null
or empty. |
static boolean |
isEmpty(java.util.Map m)
Returns true iff the Map is either null
or empty. |
static java.util.Iterator |
iterator(java.util.Collection c)
Returns the collections's iterator, treating null
as an empty list. |
static java.util.Collection |
map(java.lang.Class resultClass,
java.util.Collection c,
Function1 f)
Returns a new collection of the specified result class and with elements obtained by calling the specified function on the corresponding elements of the original collection. |
static java.util.Collection |
map(java.util.Collection c,
Function1 f)
Returns a new collection of the same class as the original and with corresponding elements obtained by calling the specified function. |
static java.util.List |
replaceFirst(java.lang.Object from,
java.lang.Object to,
java.util.List source)
Replaces the first occurrence of an item in a list, returning the modified list. |
| Methods inherited from class java.lang.Object |
|
| Method Detail |
public static final boolean isEmpty(java.util.Collection c)
null
or empty.public static final boolean isEmpty(java.util.Map m)
null
or empty.public static final java.util.Iterator iterator(java.util.Collection c)
null
as an empty list.public static java.util.List ensureList(java.util.List list)
null.
public static java.util.List replaceFirst(java.lang.Object from,
java.lang.Object to,
java.util.List source)
public static boolean equalAsSets(java.util.List a,
java.util.List b)
public static java.util.Collection intersection(java.util.Collection a,
java.util.Collection b)
public static java.util.Collection difference(java.util.Collection a,
java.util.Collection b)
public static java.util.Collection map(java.util.Collection c,
Function1 f)
public static java.util.Collection map(java.lang.Class resultClass,
java.util.Collection c,
Function1 f)
public static java.util.Collection filter(java.util.Collection c,
Predicate1 p)
public static java.util.Collection filter(java.lang.Class resultClass,
java.util.Collection c,
Predicate1 p)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||