Stream流处理list排序
时间:2019-08-08 16:33:59
收藏:0
阅读:957
代码:List<Map<String,Object>> list = null;
//list中放入数据集后根据每一笔map中的order_no字段进行冒泡排序
list.sort((Map<String,Object> h1,Map<String,Object> h2) -> ((String) h1.get("order_no")).compareTo((String)h2.get("order_no")));
原文:https://www.cnblogs.com/sikuaiwu/p/11321320.html
评论(0)