Changeset 7309 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2014-07-12T20:45:45+02:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/validation/tests/Highways.java
r7273 r7309 151 151 152 152 final HashSet<OsmPrimitive> referrers = new HashSet<>(); 153 referrers.addAll(way.firstNode().getReferrers()); 154 referrers.addAll(way.lastNode().getReferrers()); 153 154 if (way.isClosed()) { 155 // for closed way we need to check all adjacent ways 156 for (Node n: way.getNodes()) { 157 referrers.addAll(n.getReferrers()); 158 } 159 } else { 160 referrers.addAll(way.firstNode().getReferrers()); 161 referrers.addAll(way.lastNode().getReferrers()); 162 } 155 163 156 164 return Utils.exists(Utils.filteredCollection(referrers, Way.class), new Predicate<Way>() {
Note:
See TracChangeset
for help on using the changeset viewer.