Changeset 1762 in josm for trunk/src/org/openstreetmap/josm/data
- Timestamp:
- 2009-07-11T09:32:42+02:00 (17 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/data/osm
- Files:
-
- 4 edited
-
Node.java (modified) (1 diff)
-
OsmPrimitive.java (modified) (1 diff)
-
Relation.java (modified) (1 diff)
-
Way.java (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/Node.java
r1750 r1762 107 107 } 108 108 109 /**110 * @deprecated111 * @see #hasEqualSemanticAttributes(OsmPrimitive)112 * @see #hasEqualTechnicalAttributes(OsmPrimitive)113 */114 @Deprecated115 @Override public boolean realEqual(OsmPrimitive osm, boolean semanticOnly) {116 if (osm instanceof Node) {117 if (super.realEqual(osm, semanticOnly)) {118 if ((coor == null) && ((Node)osm).coor == null)119 return true;120 if (coor != null)121 return coor.equals(((Node)osm).coor);122 }123 }124 return false;125 }126 127 109 @Override 128 110 public boolean hasEqualSemanticAttributes(OsmPrimitive other) { -
trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
r1690 r1762 284 284 clearCached(); 285 285 clearErrors(); 286 }287 288 /**289 * Perform an equality compare for all non-volatile fields not only for the id290 * but for the whole object (for conflict resolving)291 * @param semanticOnly if <code>true</code>, modified flag and timestamp are not compared292 *293 * @deprecated294 * @see #hasEqualSemanticAttributes(OsmPrimitive)295 * @see #hasEqualTechnicalAttributes(OsmPrimitive)296 */297 @Deprecated298 public boolean realEqual(OsmPrimitive osm, boolean semanticOnly) {299 return id == osm.id300 && incomplete == osm.incomplete301 && deleted == osm.deleted302 && (semanticOnly || (303 modified == osm.modified304 && timestamp == osm.timestamp305 && version == osm.version306 && visible == osm.visible307 && (user == null ? osm.user==null : user==osm.user))308 )309 && (keys == null ? osm.keys==null : keys.equals(osm.keys));310 286 } 311 287 -
trunk/src/org/openstreetmap/josm/data/osm/Relation.java
r1690 r1762 68 68 // adding members in string increases memory usage a lot and overflows for looped relations 69 69 return "{Relation id="+id+" version="+version+"}"; 70 }71 72 @Deprecated73 @Override public boolean realEqual(OsmPrimitive osm, boolean semanticOnly) {74 return osm instanceof Relation ? super.realEqual(osm, semanticOnly) && members.equals(((Relation)osm).members) : false;75 70 } 76 71 -
trunk/src/org/openstreetmap/josm/data/osm/Way.java
r1690 r1762 99 99 if (incomplete) return "{Way id="+id+" version="+version+" (incomplete)}"; 100 100 return "{Way id="+id+" version="+version+" nodes="+Arrays.toString(nodes.toArray())+"}"; 101 }102 103 @Deprecated104 @Override public boolean realEqual(OsmPrimitive osm, boolean semanticOnly) {105 return osm instanceof Way ? super.realEqual(osm, semanticOnly) && nodes.equals(((Way)osm).nodes) : false;106 101 } 107 102
Note:
See TracChangeset
for help on using the changeset viewer.
