| Package | Description |
|---|---|
| com.vip.vjtools.vjkit.base.type | |
| com.vip.vjtools.vjkit.collection |
| Modifier and Type | Method and Description |
|---|---|
static <L,R> Pair<L,R> |
Pair.of(L left,
R right)
根据等号左边的泛型,自动构造合适的Pair
|
| Modifier and Type | Method and Description |
|---|---|
static <T extends Object & Comparable<? super T>> |
CollectionUtil.minAndMax(Collection<? extends T> coll)
同时返回无序集合中的最小值和最大值,使用元素默认排序
在返回的Pair中,第一个为最小值,第二个为最大值
|
static <T> Pair<T,T> |
CollectionUtil.minAndMax(Collection<? extends T> coll,
Comparator<? super T> comp)
返回无序集合中的最小值和最大值
在返回的Pair中,第一个为最小值,第二个为最大值
|
Copyright © 2018. All rights reserved.