今日は、プロジェクトで使用され、特に記録について
一覧<地図<文字列、オブジェクト>> resourceCatalogFrontVoList = resourceMapper.selectPublishResourceCatalogList(キーワード、SYSID、shareType、openAttribute、 classifyId、resourcetypeの、ページ)。 // 排序 コンパレータ<地図<文字列、オブジェクト>>コンパレータ= Comparator.comparing(項目- > item.get(SORTFIELD).toString()); もし(FrontConstant.SORT_TYPE_ASC == SORTTYPE){ // 升序 resourceCatalogFrontVoList.sort(コンパレータ)。 } 他{ resourceCatalogFrontVoList.sort(comparator.reversed())。 } // 分页 リターン page.setRecords(resourceCatalogFrontVoList)。