将一个list集合 ,按照每count个数进行划分为多个list
public List<List<T>> splitCollection(List<T> dataList, int count) {
return Lists.partition(dataList, count);
}
public static void main(String[] args) {
List<String> objects = new ArrayList<>();
objects.add("111");
objects.add("222");
objects.add("333");
List<List<String>> partition = Lists.partition(objects, 1);
}