/** * list分页 * @param dataList * @param currentPage * @param pageSize * @return */ private static List startPage(ListdataList, int currentPage, int pageSize) { List currentPageList = new ArrayList<>(); if (dataList != null && dataList.size() > 0) { int currIdx = (currentPage > 1 ? (currentPage - 1) * pageSize : 0); for (int i = 0; i < pageSize && i < dataList.size() - currIdx; i++) { String data = dataList.get(currIdx+i); currentPageList.add(data); } } return currentPageList; }