Mercurial > hg > Database > Christie
changeset 255:a46033945af9
tweak
author | ichikitakahiro <e165713@ie.u-ryukyu.ac.jp> |
---|---|
date | Fri, 24 Jan 2020 18:26:24 +0900 |
parents | 04bb299f18bd |
children | ed79640965a5 |
files | src/test/java/christie/example/RemoteTake/CreateRemoteTakeTest.java src/test/java/christie/example/RemoteTake/RemoteTakeTest.java |
diffstat | 2 files changed, 38 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/test/java/christie/example/RemoteTake/CreateRemoteTakeTest.java Fri Jan 24 18:26:24 2020 +0900 @@ -0,0 +1,14 @@ +package christie.example.RemoteTake; + +import christie.codegear.CodeGear; +import christie.codegear.CodeGearManager; + +public class CreateRemoteTakeTest extends CodeGear{ + + @Override + protected void run(CodeGearManager cgm) { + cgm.setup(new RemoteTakeTest()); + put("count", 1); + put("cgmID", cgm.cgmID); + } +}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/test/java/christie/example/RemoteTake/RemoteTakeTest.java Fri Jan 24 18:26:24 2020 +0900 @@ -0,0 +1,24 @@ +package christie.example.RemoteTake; + +import christie.annotation.PeekFrom; +import christie.annotation.TakeFrom; +import christie.codegear.CodeGear; +import christie.codegear.CodeGearManager; + +public class RemoteTakeTest extends CodeGear{ + + @TakeFrom("remote") + int count; + + @PeekFrom("remote") + int cgmID; + + @Override + protected void run(CodeGearManager cgm) { + if (count <= 10){ + System.out.println(cgmID + " : " + count); + cgm.setup(new RemoteTakeTest()); + put("count", count + 1); + } + } +}