annotate daemon/ThreadPoolExecutors.cs @ 29:0cd2684e401b

update InputDataGear and more
author riono <e165729@ie.u-ryukyu.ac.jp>
date Thu, 21 Jan 2021 01:18:26 +0900
parents efb06874a34e
children 96fc5e71274e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
26
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 using System.Threading;
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
2 using System.Threading.Tasks;
27
efb06874a34e update RemoteDataGearManager
riono <e165729@ie.u-ryukyu.ac.jp>
parents: 26
diff changeset
3 using Christie_net.codegear;
26
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4
27
efb06874a34e update RemoteDataGearManager
riono <e165729@ie.u-ryukyu.ac.jp>
parents: 26
diff changeset
5 namespace Christie_net.daemon {
26
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 public class ThreadPoolExecutors {
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
7
29
0cd2684e401b update InputDataGear and more
riono <e165729@ie.u-ryukyu.ac.jp>
parents: 27
diff changeset
8 // TODO: どこかしらでThreadPoolの設定をする
0cd2684e401b update InputDataGear and more
riono <e165729@ie.u-ryukyu.ac.jp>
parents: 27
diff changeset
9
26
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 public ThreadPoolExecutors() {
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
11
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
12 }
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
13
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
14 public void CreateThreadPool() {
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
15
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
16 }
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
17
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 public void Execute(CodeGearExecutor command) {
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
19 Task.Factory.StartNew(() => command.Run());
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 }
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
21 }
45ff08d59fda update CGM
riono <e165729@ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 }