Mercurial > hg > Database > Alice
annotate src/alice/test/codesegment/local/TestCodeSegment.java @ 169:16418c2c3e72 working
minor change
author | sugi |
---|---|
date | Tue, 18 Dec 2012 14:49:36 +0900 (2012-12-18) |
parents | 206c7dd9cb48 |
children | d7816b9b72e9 |
rev | line source |
---|---|
22
2ca2d961a8d2
implements outline of TopologyManager
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
19
diff
changeset
|
1 package alice.test.codesegment.local; |
3 | 2 |
3 import alice.codesegment.CodeSegment; | |
18
72dd27d952b0
change InputDataSegment API
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
16
diff
changeset
|
4 import alice.datasegment.CommandType; |
33
20c67f673224
change name of DataSegmentReceiver
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
32
diff
changeset
|
5 import alice.datasegment.Receiver; |
3 | 6 |
7 public class TestCodeSegment extends CodeSegment { | |
8 | |
119 | 9 static int count = 0; |
10 | |
57 | 11 // create input datasegment arg1 |
33
20c67f673224
change name of DataSegmentReceiver
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
32
diff
changeset
|
12 Receiver arg1 = ids.create(CommandType.PEEK); |
97 | 13 public TestCodeSegment(){ |
14 arg1.setKey("key1"); | |
15 } | |
16 public TestCodeSegment(int index){ | |
17 arg1.setKey("key1",index); | |
18 } | |
16 | 19 |
3 | 20 @Override |
21 public void run() { | |
132 | 22 //System.out.println("index = " + arg1.index); |
169 | 23 System.out.println("data = " + arg1.val); |
132 | 24 //System.out.println(arg1.val.getType()); |
97 | 25 |
150 | 26 |
27 /* | |
18
72dd27d952b0
change InputDataSegment API
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
16
diff
changeset
|
28 TestCodeSegment cs = new TestCodeSegment(); |
71
a3a2605e16a2
change checking debug mode of logger
kazz <kazz@cr.ie.u-ryukyu.ac.jp>
parents:
57
diff
changeset
|
29 cs.arg1.setKey("key1", arg1.index); |
97 | 30 */ |
107 | 31 |
169 | 32 new TestCodeSegment(); |
33 //new TestCodeSegment(arg1.index); | |
34 | |
35 | |
57 | 36 // DataSegment.get("local").update |
169 | 37 //ods.update("local", "key1", arg1.index); |
119 | 38 |
3 | 39 } |
40 | |
41 } |