将List<E>内对象按照某个字段排序

主要用到java.util的Collections类

Collections.sort(list);

其中,E必须实现Comparable<E>接口

原文地址:https://www.cnblogs.com/deolin/p/7777012.html