Mercurial > hg > Members > sugi > javafx
view src/alice/test/topology/aquarium/fx/UpdateData.java @ 23:b77c2c6db854
minor change
author | e095732 |
---|---|
date | Mon, 01 Jul 2013 20:02:03 +0900 |
parents | 43ae0c87885b |
children |
line wrap: on
line source
package alice.test.topology.aquarium.fx; import alice.codesegment.CodeSegment; import alice.datasegment.CommandType; import alice.datasegment.Receiver; public class UpdateData extends CodeSegment { private Receiver data1 = ids.create(CommandType.PEEK); private Receiver data2 = ids.create(CommandType.TAKE); public UpdateData(FishData fd){ ods.put("local", "diff", fd); data1.setKey("FISH0"); data2.setKey("diff"); } @Override public void run() { FishData fd1 = data1.asClass(FishData.class); FishData fd2 = data2.asClass(FishData.class); fd1.SetXYZ(fd1.getX()+fd2.getX(), fd1.getY()+fd2.getY(), fd1.getZ()+fd2.getZ()); ods.update("local", data1.key, fd1); } }