// Collections.sort List<ObjectName> list = new ArrayList<ObjectName>(); Collections.sort(list, new Comparator<ObjectName>() { public int compare(ObjectName o1, ObjectName o2) { return o1.toString().compareTo(o2.toString()); } }); //源代码片段来自云代码http://yuncode.net