Mercurial > hg > Applications > AliceVNC
annotate src/main/java/jp/ac/u_ryukyu/alicevnc/CheckMyName.java @ 55:fe627049e289
update maven added compressed to DSM name
author | Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 16 Nov 2015 20:06:13 +0900 |
parents | 57ca704f86a3 |
children |
rev | line source |
---|---|
30 | 1 package jp.ac.u_ryukyu.alicevnc; |
2 | |
3 import alice.codesegment.CodeSegment; | |
4 import alice.datasegment.CommandType; | |
5 import alice.datasegment.Receiver; | |
6 | |
7 public class CheckMyName extends CodeSegment { | |
8 | |
9 private Receiver info = ids.create(CommandType.PEEK); | |
10 | |
52
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
11 public CheckMyName(){ |
55
fe627049e289
update maven added compressed to DSM name
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
52
diff
changeset
|
12 info.setKey("compressedLocal", "host"); |
30 | 13 } |
14 | |
15 @Override | |
16 public void run() { | |
17 if ("node0".equals(info.asString())) { | |
52
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
18 new CreateWindow("local"); |
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
19 new NegotiateVNCServer(); |
30 | 20 } else { |
52
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
21 new CreateWindow("parent"); |
30 | 22 } |
31 | 23 |
52
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
24 new ReceiveAliceVNCMessage(); |
57ca704f86a3
back version Alice tag:work-compressedDSM
Nozomi Teruya <e125769@ie.u-ryukyu.ac.jp>
parents:
47
diff
changeset
|
25 new SendChangeRequest(); |
30 | 26 } |
27 | |
28 } |