annotate Implab/PromiseEventType.cs @ 209:a867536c68fc v2

Bound promise to CancellationToken Added new states to ExecutionSate enum. Added Safe.Guard() method to handle cleanup of the result of the promise
author cin
date Wed, 16 Nov 2016 03:06:08 +0300
parents 3fbc6eb93eb1
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
104
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
1 using System;
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
2
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
3 namespace Implab {
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
4 [Flags]
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
5 public enum PromiseEventType {
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
6 Success = 1,
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
7 Error = 2,
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
8 Cancelled = 4,
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
9 /// <summary>
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
10 /// Завершено успешно, либо возникла ошибка,
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
11 /// </summary>
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
12 All = 7,
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
13 /// <summary>
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
14 /// Заврешено успешно, либо возникла ошибка.
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
15 /// </summary>
114
3fbc6eb93eb1 minor changes
cin
parents: 104
diff changeset
16 Complete = 3,
3fbc6eb93eb1 minor changes
cin
parents: 104
diff changeset
17
3fbc6eb93eb1 minor changes
cin
parents: 104
diff changeset
18 ErrorOrCancel = 6
104
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
19 }
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
20 }
5f10d54b45df renamed Promise.Last -> Promise.On
cin
parents:
diff changeset
21