diff src/alice/test/topology/movement/CheckMyName.java @ 94:38f4021353c5 working

"setKey" is in the instance
author sugi
date Mon, 18 Jun 2012 17:10:23 +0900
parents 6601f8854126
children df786bf8f036
line wrap: on
line diff
--- a/src/alice/test/topology/movement/CheckMyName.java	Tue Jun 05 16:33:28 2012 +0900
+++ b/src/alice/test/topology/movement/CheckMyName.java	Mon Jun 18 17:10:23 2012 +0900
@@ -11,6 +11,7 @@
 	Receiver host = ids.create(CommandType.PEEK);
 	Pattern pattern = Pattern.compile("^(node|cli)([0-9]+)$");
 	
+	
 	@Override
 	public void run(){
 		
@@ -26,30 +27,19 @@
 			
 			MakeFrame frame =  new MakeFrame();
 			
+			MakeObject obj3 = new MakeObject(frame);
+			frame.register(obj3);
+			new CheckFishLocation(obj3,"fish3X");
+			
 			MakeObject obj = new MakeObject(frame);
 			frame.register(obj);
-			CheckFishLocation cs = new CheckFishLocation(obj,"fish1X");
-			cs.host.setKey("local","host");
-			cs.nowX.setKey("parent","fish1X");
-						
-			MakeObject obj2 = new MakeObject(frame);
-			frame.register(obj2);
-			CheckFishLocation cs2 = new CheckFishLocation(obj2,"fish2X");
-			cs2.host.setKey("local","host");
-			cs2.nowX.setKey("parent","fish2X");
-			
-			MakeObject obj3 = new MakeObject(frame);
-			frame.register(obj3);
-			CheckFishLocation cs3 = new CheckFishLocation(obj3,"fish3X");
-			cs3.host.setKey("local","host");
-			cs3.nowX.setKey("parent","fish3X");
-			
-			
+			new CheckFishLocation(obj,"fish1X");
+									
 		}else if(type.equals("node")){
 			System.out.println("node0");
+			ods.update("local", "fish3X", 0);
 			ods.update("local", "fish1X", -1000);
-			ods.update("local", "fish2X", -1000);
-			ods.update("local", "fish3X", 0);
+	
 			
 		}
 	}