Timing, Attacks
[iotcloud.git] / version2 / src / java / iotcloud / LocalComm.java
index d6d34914d36229195ca2ec4ee9587e93ca405fc5..c2eb11b7bf8e9ce4b4402506fb9a93a108a7c0a3 100644 (file)
@@ -9,14 +9,17 @@ class LocalComm {
         t2 = _t2;
     }
 
-    public byte[] sendDataToLocalDevice(Long deviceId, byte[] data) {
-        if (deviceId == t1.getId()) {
-            return t1.localCommInput(data);
-        } else if (deviceId == t2.getId()) {
-            return t2.localCommInput(data);
-        }
-        else {
+    public byte[] sendDataToLocalDevice(Long deviceId, byte[] data) throws InterruptedException{
+        System.out.println("Passing Locally");
+
+        if (deviceId == t1.getMachineId()) {
+            // return t1.localCommInput(data);
+        } else if (deviceId == t2.getMachineId()) {
+            // return t2.localCommInput(data);
+        } else {
             throw new Error("Cannot send to " + deviceId + " using this local comm");
         }
+
+        return new byte[0];
     }
 }
\ No newline at end of file