Category: Java Tips

How to sort List(Map) by Stream 0

How to sort List(Map) by Stream

public void sortLastOnlineList(CloudRInfoPo cloudRInfoPo, List<Map<String, Object>> result) { if (!StringUtils.isEmpty(cloudRInfoPo.getDuration()) || "desc".equals(cloudRInfoPo.getSort())) { } if (!StringUtils.isEmpty(cloudRInfoPo.getDuration()) || "asc".equals(cloudRInfoPo.getSort())) { } }