Index: trunk/test/functional/org/openstreetmap/josm/io/MultiFetchServerObjectReaderTest.java
===================================================================
--- trunk/test/functional/org/openstreetmap/josm/io/MultiFetchServerObjectReaderTest.java	(revision 2072)
+++ trunk/test/functional/org/openstreetmap/josm/io/MultiFetchServerObjectReaderTest.java	(revision 2077)
@@ -28,4 +28,5 @@
 import org.openstreetmap.josm.data.osm.Node;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
+import org.openstreetmap.josm.data.osm.OsmPrimitiveType;
 import org.openstreetmap.josm.data.osm.Relation;
 import org.openstreetmap.josm.data.osm.RelationMember;
@@ -247,5 +248,5 @@
         while(it.hasNext()) {
             Node n1 = it.next();
-            Node n2 = (Node)ds.getPrimitiveById(n1.id);
+            Node n2 = (Node)ds.getPrimitiveById(n1.getId(), OsmPrimitiveType.NODE);
             assertNotNull(n2);
             assertEquals(n2.get("name"),n2.get("name"));
@@ -266,5 +267,5 @@
         while(it.hasNext()) {
             Way w1 = it.next();
-            Way w2 = (Way)ds.getPrimitiveById(w1.id);
+            Way w2 = (Way)ds.getPrimitiveById(w1.getId(), OsmPrimitiveType.WAY);
             assertNotNull(w2);
             assertEquals(w2.getNodesCount(), w1.getNodesCount());
@@ -286,5 +287,5 @@
         while(it.hasNext()) {
             Relation r1 = it.next();
-            Relation r2 = (Relation)ds.getPrimitiveById(r1.id);
+            Relation r2 = (Relation)ds.getPrimitiveById(r1.getId(), OsmPrimitiveType.RELATION);
             assertNotNull(r2);
             assertEquals(r2.getMembersCount(), r1.getMembersCount());
@@ -306,5 +307,5 @@
         while(it.hasNext()) {
             Node n1 = it.next();
-            Node n2 = (Node)ds.getPrimitiveById(n1.id);
+            Node n2 = (Node)ds.getPrimitiveById(n1.getId(), OsmPrimitiveType.NODE);
             assertNotNull(n2);
             assertEquals(n2.get("name"),n2.get("name"));
@@ -327,5 +328,5 @@
         while(it.hasNext()) {
             Node n1 = it.next();
-            Node n2 = (Node)ds.getPrimitiveById(n1.id);
+            Node n2 = (Node)ds.getPrimitiveById(n1.getId(), OsmPrimitiveType.NODE);
             assertNotNull(n2);
             assertEquals(n2.get("name"),n2.get("name"));
Index: trunk/test/functional/org/openstreetmap/josm/io/OsmServerBackreferenceReaderTest.java
===================================================================
--- trunk/test/functional/org/openstreetmap/josm/io/OsmServerBackreferenceReaderTest.java	(revision 2072)
+++ trunk/test/functional/org/openstreetmap/josm/io/OsmServerBackreferenceReaderTest.java	(revision 2077)
@@ -27,4 +27,5 @@
 import org.openstreetmap.josm.data.osm.Node;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
+import org.openstreetmap.josm.data.osm.OsmPrimitiveType;
 import org.openstreetmap.josm.data.osm.Relation;
 import org.openstreetmap.josm.data.osm.RelationMember;
@@ -253,5 +254,5 @@
         assertEquals(0, referers.relations.size());
         for (Way way: referers.ways) {
-            assertEquals(w.id, way.id);
+            assertEquals(w.getId(), way.getId());
             assertEquals(false, way.incomplete);
         }
@@ -272,5 +273,5 @@
         assertEquals(0, referers.relations.size());
         for (Way way: referers.ways) {
-            assertEquals(w.id, way.id);
+            assertEquals(w.getId(), way.getId());
             assertEquals(false, way.incomplete);
             assertEquals(10, w.getNodesCount());
@@ -319,12 +320,12 @@
         Set<Long> expectedNodeIds = new HashSet<Long>();
         for (Way way: referers.ways) {
-            Way orig = (Way)ds.getPrimitiveById(way.id);
+            Way orig = (Way)ds.getPrimitiveById(way.getId(), OsmPrimitiveType.WAY);
             for(Node n: orig.getNodes()) {
-                expectedNodeIds.add(n.id);
+                expectedNodeIds.add(n.getId());
             }
         }
         assertEquals(expectedNodeIds.size(), referers.nodes.size());
         for (Node n : referers.nodes) {
-            assertEquals(true, expectedNodeIds.contains(n.id));
+            assertEquals(true, expectedNodeIds.contains(n.getId()));
         }
 
@@ -352,20 +353,20 @@
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 7);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 8);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 9);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
 
         for (Relation r1: referers.relations) {
-            if (! referringRelationsIds.contains(r1.id)) {
+            if (! referringRelationsIds.contains(r1.getId())) {
                 assertEquals(true, r1.incomplete);
             }
@@ -378,20 +379,20 @@
         for (RelationMember m : lookupRelation(ds, 6).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 7).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 8).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 9).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
@@ -399,5 +400,5 @@
         assertEquals(expectedWayIds.size(), referers.ways.size());
         for (Way w1 : referers.ways) {
-            assertEquals(true, expectedWayIds.contains(w1.id));
+            assertEquals(true, expectedWayIds.contains(w1.getId()));
             assertEquals(true, w1.incomplete);
         }
@@ -412,5 +413,5 @@
         if (way == null)return ret;
         for (Node n: way.getNodes()) {
-            ret.add(n.id);
+            ret.add(n.getId());
         }
         return ret;
@@ -422,5 +423,5 @@
         for (RelationMember m: r.getMembers()) {
             if (m.isNode()) {
-                ret.add(m.getMember().id);
+                ret.add(m.getMember().getId());
             } else if (m.isWay()) {
                 ret.addAll(getNodeIdsInWay(m.getWay()));
@@ -448,17 +449,17 @@
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 7);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 8);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
         r = lookupRelation(referers, 9);
         assertNotNull(r);
         assertEquals(false, r.incomplete);
-        referringRelationsIds.add(r.id);
+        referringRelationsIds.add(r.getId());
 
         // all relations are fully loaded
@@ -474,24 +475,24 @@
         for (RelationMember m : lookupRelation(ds, 6).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 7).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 8).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (RelationMember m : lookupRelation(ds, 9).getMembers()) {
             if (m.isWay()) {
-                expectedWayIds.add(m.getMember().id);
+                expectedWayIds.add(m.getMember().getId());
             }
         }
         for (long id : expectedWayIds) {
-            Way w = (Way)referers.getPrimitiveById(id);
+            Way w = (Way)referers.getPrimitiveById(id, OsmPrimitiveType.WAY);
             assertNotNull(w);
             assertEquals(false, w.incomplete);
@@ -506,5 +507,5 @@
         assertEquals(expectedNodeIds.size(), referers.nodes.size());
         for(Node n : referers.nodes) {
-            assertEquals(true, expectedNodeIds.contains(n.id));
+            assertEquals(true, expectedNodeIds.contains(n.getId()));
         }
     }
