コード例 #1
0
 internal InternalFutureTask(CloseableExecutorService executorService,
                             ICallable <T> task)
     : base(task)
 {
     _executorService = executorService;
     _executorService.futures.TryAdd(this, this);
 }
コード例 #2
0
 public InternalScheduledFutureTask(CloseableExecutorService executorService,
                                    IFuture <object> scheduledFuture)
 {
     _executorService = executorService;
     _scheduledFuture = scheduledFuture;
     executorService.futures.TryAdd(scheduledFuture, scheduledFuture);
 }
コード例 #3
0
 internal InternalFutureTask(CloseableExecutorService executorService,
                             ICallable <T> task,
                             CancellationTokenSource tokenSource)
     : base(task, tokenSource)
 {
     _executorService = executorService;
     _executorService.futures.TryAdd(this, this);
 }