345
|
1 package alice.test.topology.ring;
|
|
2
|
|
3 import org.msgpack.type.ValueFactory;
|
|
4
|
|
5 import alice.codesegment.CodeSegment;
|
|
6 import alice.datasegment.CommandType;
|
|
7 import alice.datasegment.Receiver;
|
|
8
|
|
9 public class RingFinish extends CodeSegment {
|
|
10
|
|
11 private String sendKey;
|
|
12 public Receiver finish = ids.create(CommandType.TAKE);
|
|
13
|
|
14 public RingFinish(String sendKey) {
|
|
15 this.sendKey = sendKey;
|
|
16 }
|
|
17
|
|
18 @Override
|
|
19 public void run() {
|
|
20 ods.put(sendKey, "finish", ValueFactory.createNilValue());
|
|
21 ods.finish(sendKey);
|
|
22 }
|
|
23
|
|
24 }
|