Changeset 597 in josm for trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
- Timestamp:
- 2008-04-07T22:04:53+02:00 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
r529 r597 83 83 84 84 /** 85 * true if this object has direction dependant tags (e.g. oneway) 86 */ 87 public boolean hasDirectionKeys = false; 88 89 /** 85 90 * If set to true, this object is currently selected. 86 91 */ … … 112 117 public static Collection<String> uninteresting = 113 118 new HashSet<String>(Arrays.asList(new String[] {"source", "note", "created_by"})); 119 120 /** 121 * Contains a list of direction-dependent keys that do not make an object 122 * direction dependent. 123 */ 124 public static Collection<String> directionKeys = 125 new HashSet<String>(Arrays.asList(new String[] {"oneway", "incline", "incline_steep", "aerialway"})); 114 126 115 127 /** … … 186 198 } 187 199 checkTagged(); 200 checkDirectionTagged(); 188 201 } 189 202 /** … … 197 210 } 198 211 checkTagged(); 212 checkDirectionTagged(); 199 213 } 200 214 … … 266 280 } 267 281 } 282 /** 283 * Updates the "hasDirectionKeys" flag. "keys" property should probably be made private 284 * to make sure this gets called when keys are set. 285 */ 286 public void checkDirectionTagged() { 287 hasDirectionKeys = false; 288 if (keys != null) { 289 for (Entry<String,String> e : keys.entrySet()) { 290 if (directionKeys.contains(e.getKey())) { 291 hasDirectionKeys = true; 292 break; 293 } 294 } 295 } 296 297 } 268 298 269 299 }
Note:
See TracChangeset
for help on using the changeset viewer.
