Mercurial > hg > Database > Alice
view src/main/java/alice/topology/manager/createABSIPList.java @ 345:8f71c3e6f11d
Change directory structure Maven standard
author | sugi |
---|---|
date | Wed, 16 Apr 2014 18:26:07 +0900 |
parents | |
children |
line wrap: on
line source
package alice.topology.manager; import java.util.List; import alice.codesegment.CodeSegment; import alice.datasegment.CommandType; import alice.datasegment.Receiver; import alice.topology.HostMessage; public class createABSIPList extends CodeSegment{ private Receiver rData = ids.create(CommandType.TAKE); private Receiver hlist = ids.create(CommandType.PEEK); public createABSIPList(){ rData.setKey("_ABS_IP"); hlist.setKey("_ABSIPTABLE"); } @Override public void run() { HostMessage host = rData.asClass(HostMessage.class); @SuppressWarnings("unchecked") List<HostMessage> ABSIPList = hlist.asClass(List.class); ABSIPList.add(host); ods.update("_ABSIPTABLE", ABSIPList); new createABSIPList(); } }