List<Menu> m = new ArrayList<>(); HashSet<Menu> mm = new HashSet<>(menus); m.addAll(mm); m.sort(new Comparator<Menu>() { @Override public int compare(Menu o1, Menu o2) { if (o1.getSortNum() >= o2.getSortNum()) return 1; return -1; } })
List m = new ArrayListHashSet mm = new HashSetm.addAll(mm);m.sort(new Comparator() {@Overridepublic int compare(Menu o1, Menu o2) {if (o1.getSortNum() >= o2.getSortNum())return 1;retur