|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweiss.util.Collections
public class Collections
Instanceless class contains static methods that operate on collections.
Method Summary | ||
---|---|---|
static
|
max(Collection<? extends AnyType> coll)
Returns the maximum object in the collection, using default ordering |
|
static
|
max(Collection<? extends AnyType> coll,
Comparator<? super AnyType> cmp)
Returns the maximum object in the collection, using comparator. |
|
static
|
reverseOrder()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static <AnyType extends java.lang.Object & java.lang.Comparable<? super AnyType>> AnyType max(Collection<? extends AnyType> coll)
coll
- the collection.
NoSuchElementException
- if coll is empty.
java.lang.ClassCastException
- if objects in collection cannot be compared.public static <AnyType> AnyType max(Collection<? extends AnyType> coll, Comparator<? super AnyType> cmp)
coll
- the collection.cmp
- the comparator.
NoSuchElementException
- if coll is empty.
java.lang.ClassCastException
- if objects in collection cannot be compared.public static <AnyType> Comparator<AnyType> reverseOrder()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |