Changeset 10619 in josm for trunk/src/org/openstreetmap/josm/data
- Timestamp:
- 2016-07-24T00:19:35+02:00 (8 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/data
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/APIDataSet.java
r10608 r10619 4 4 import java.util.ArrayList; 5 5 import java.util.Collection; 6 import java.util.Collections;7 6 import java.util.HashMap; 8 7 import java.util.HashSet; … … 72 71 } 73 72 OsmPrimitiveComparator c = new OsmPrimitiveComparator(false, true); 74 Collections.sort(toDelete,c);75 Collections.sort(toAdd,c);76 Collections.sort(toUpdate,c);73 toDelete.sort(c); 74 toAdd.sort(c); 75 toUpdate.sort(c); 77 76 } 78 77 … … 332 331 } 333 332 List<Relation> ret = new ArrayList<>(relations); 334 Collections.sort( 335 ret, 336 (o1, o2) -> Integer.compare(uploadOrder.indexOf(o1), uploadOrder.indexOf(o2)) 337 ); 333 ret.sort((o1, o2) -> Integer.compare(uploadOrder.indexOf(o1), uploadOrder.indexOf(o2))); 338 334 return ret; 339 335 } -
trunk/src/org/openstreetmap/josm/data/osm/NoteData.java
r10608 r10619 102 102 public Collection<Note> getSortedNotes() { 103 103 final List<Note> list = new ArrayList<>(noteList); 104 Collections.sort(list,comparator);104 list.sort(comparator); 105 105 return list; 106 106 } -
trunk/src/org/openstreetmap/josm/data/osm/history/History.java
r10608 r10619 4 4 import java.text.MessageFormat; 5 5 import java.util.ArrayList; 6 import java.util.Collections;7 6 import java.util.Date; 8 7 import java.util.List; … … 69 68 public History sortAscending() { 70 69 List<HistoryOsmPrimitive> copy = new ArrayList<>(versions); 71 Collections.sort(copy,(o1, o2) -> o1.compareTo(o2));70 copy.sort((o1, o2) -> o1.compareTo(o2)); 72 71 return new History(id, type, copy); 73 72 } … … 79 78 public History sortDescending() { 80 79 List<HistoryOsmPrimitive> copy = new ArrayList<>(versions); 81 Collections.sort(copy,(o1, o2) -> o2.compareTo(o1));80 copy.sort((o1, o2) -> o2.compareTo(o1)); 82 81 return new History(id, type, copy); 83 82 }
Note:
See TracChangeset
for help on using the changeset viewer.