Mercurial > pub > ImplabNet
comparison Implab/FuncTask.cs @ 244:eee3e49dd1ff v3
working on promises
| author | cin |
|---|---|
| date | Thu, 25 Jan 2018 19:09:16 +0300 |
| parents | 40d7fed4a09e |
| children |
comparison
equal
deleted
inserted
replaced
| 243:b1e0ffdf3451 | 244:eee3e49dd1ff |
|---|---|
| 1 using System; | 1 using System; |
| 2 using System.Threading; | 2 using System.Threading; |
| 3 | 3 |
| 4 namespace Implab { | 4 namespace Implab { |
| 5 public class FuncTask<T> : FuncTaskBase<T>, IDeferred { | 5 public class FuncTask<T> : FuncTaskBase<T>, IResolvable { |
| 6 readonly Func<T> m_task; | 6 readonly Func<T> m_task; |
| 7 | 7 |
| 8 public FuncTask(Func<T> task, Func<Exception, T> error, Func<Exception, T> cancel, bool autoCancellable) : base(error, cancel, autoCancellable) { | 8 public FuncTask(Func<T> task, Func<Exception, T> error, Func<Exception, T> cancel, bool autoCancellable) : base(error, cancel, autoCancellable) { |
| 9 m_task = task; | 9 m_task = task; |
| 10 } | 10 } |
