Collections.sort(list, new Comparator() { public int compare(Object a, Object b) { int one = ((Bean) a).getPriority(); int two = ((Bean) b).getPriority(); return one - two; } });
list object 排序问题
最新推荐文章于 2024-06-27 11:14:03 发布
Collections.sort(list, new Comparator() { public int compare(Object a, Object b) { int one = ((Bean) a).getPriority(); int two = ((Bean) b).getPriority(); return one - two; } });