Mercurial > hg > Applications > AliceVNC
diff src/main/java/jp/ac/u_ryukyu/alicevnc/SendChangeRequest.java @ 24:36a9a7de314d
root can receive message
author | sugi |
---|---|
date | Sat, 08 Nov 2014 10:57:01 +0900 |
parents | edf1b800d8b9 |
children | 6cb444e8e646 |
line wrap: on
line diff
--- a/src/main/java/jp/ac/u_ryukyu/alicevnc/SendChangeRequest.java Fri Nov 07 17:48:48 2014 +0900 +++ b/src/main/java/jp/ac/u_ryukyu/alicevnc/SendChangeRequest.java Sat Nov 08 10:57:01 2014 +0900 @@ -2,13 +2,14 @@ import java.util.List; +import jp.ac.u_ryukyu.alicevnc.ChangeRequestMessage.MessageType; import alice.codesegment.CodeSegment; import alice.datasegment.CommandType; import alice.datasegment.Receiver; public class SendChangeRequest extends CodeSegment { - private Receiver info = ids.create(CommandType.PEEK); // hostName + private Receiver info = ids.create(CommandType.PEEK); // hostName private Receiver info1 = ids.create(CommandType.PEEK); // connection list private Receiver info2 = ids.create(CommandType.PEEK); // AliceVNCConfig private Receiver info3 = ids.create(CommandType.TAKE); // request @@ -28,9 +29,9 @@ @SuppressWarnings("unchecked") List<String> clist = info1.asClass(List.class); - ChangeRequestMessage mes = new ChangeRequestMessage(); + ChangeRequestMessage mes = new ChangeRequestMessage(MessageType.ChangeRequest); mes.changeServer = config.getAllowChange(); - mes.requestNodeName = hostname; + mes.name = hostname; String address = "local"; if (clist.contains("parent")){ // this node is not root. compare node0 is better?