using System; using Cpp2IlInjected; namespace System.Threading.Tasks { /// Specifies the behavior for a task that is created by using the or method. // Token: 0x0200039B RID: 923 [Token(Token = "0x200039B")] [Flags] [Serializable] public enum TaskContinuationOptions { /// When no continuation options are specified, specifies that default behavior should be used when executing a continuation. The continuation runs asynchronously when the antecedent task completes, regardless of the antecedent's final property value. It the continuation is a child task, it is created as a detached nested task. // Token: 0x040012E0 RID: 4832 [Token(Token = "0x40012E0")] None = 0, /// A hint to a to schedule task in the order in which they were scheduled, so that tasks scheduled sooner are more likely to run sooner, and tasks scheduled later are more likely to run later. // Token: 0x040012E1 RID: 4833 [Token(Token = "0x40012E1")] PreferFairness = 1, /// Specifies that a continuation will be a long-running, course-grained operation. It provides a hint to the that oversubscription may be warranted. // Token: 0x040012E2 RID: 4834 [Token(Token = "0x40012E2")] LongRunning = 2, /// Specifies that the continuation, if it is a child task, is attached to a parent in the task hierarchy. The continuation can be a child task only if its antecedent is also a child task. By default, a child task (that is, an inner task created by an outer task) executes independently of its parent. You can use the option so that the parent and child tasks are synchronized. /// Note that if a parent task is configured with the option, the option in the child task has no effect, and the child task will execute as a detached child task. /// For more information, see Attached and Detached Child Tasks. // Token: 0x040012E3 RID: 4835 [Token(Token = "0x40012E3")] AttachedToParent = 4, /// Specifies that any child task (that is, any nested inner task created by this continuation) that is created with the option and attempts to execute as an attached child task will not be able to attach to the parent task and will execute instead as a detached child task. For more information, see Attached and Detached Child Tasks. // Token: 0x040012E4 RID: 4836 [Token(Token = "0x40012E4")] DenyChildAttach = 8, /// Specifies that tasks created by the continuation by calling methods such as or see the default scheduler () rather than the scheduler on which this continuation is running as the current scheduler. // Token: 0x040012E5 RID: 4837 [Token(Token = "0x40012E5")] HideScheduler = 16, /// In the case of continuation cancellation, prevents completion of the continuation until the antecedent has completed. // Token: 0x040012E6 RID: 4838 [Token(Token = "0x40012E6")] LazyCancellation = 32, /// Specifies that the continuation task should be run asynchronously. This option has precedence over . // Token: 0x040012E7 RID: 4839 [Token(Token = "0x40012E7")] RunContinuationsAsynchronously = 64, /// Specifies that the continuation task should not be scheduled if its antecedent ran to completion. An antecedent runs to completion if its property upon completion is . This option is not valid for multi-task continuations. // Token: 0x040012E8 RID: 4840 [Token(Token = "0x40012E8")] NotOnRanToCompletion = 65536, /// Specifies that the continuation task should not be scheduled if its antecedent threw an unhandled exception. An antecedent throws an unhandled exception if its property upon completion is . This option is not valid for multi-task continuations. // Token: 0x040012E9 RID: 4841 [Token(Token = "0x40012E9")] NotOnFaulted = 131072, /// Specifies that the continuation task should not be scheduled if its antecedent was canceled. An antecedent is canceled if its property upon completion is . This option is not valid for multi-task continuations. // Token: 0x040012EA RID: 4842 [Token(Token = "0x40012EA")] NotOnCanceled = 262144, /// Specifies that the continuation should be scheduled only if its antecedent ran to completion. An antecedent runs to completion if its property upon completion is . This option is not valid for multi-task continuations. // Token: 0x040012EB RID: 4843 [Token(Token = "0x40012EB")] OnlyOnRanToCompletion = 393216, /// Specifies that the continuation task should be scheduled only if its antecedent threw an unhandled exception. An antecedent throws an unhandled exception if its property upon completion is . /// The option guarantees that the property in the antecedent is not . You can use that property to catch the exception and see which exception caused the task to fault. If you do not access the property, the exception is unhandled. Also, if you attempt to access the property of a task that has been canceled or has faulted, a new exception is thrown. /// This option is not valid for multi-task continuations. // Token: 0x040012EC RID: 4844 [Token(Token = "0x40012EC")] OnlyOnFaulted = 327680, /// Specifies that the continuation should be scheduled only if its antecedent was canceled. An antecedent is canceled if its property upon completion is . This option is not valid for multi-task continuations. // Token: 0x040012ED RID: 4845 [Token(Token = "0x40012ED")] OnlyOnCanceled = 196608, /// Specifies that the continuation task should be executed synchronously. With this option specified, the continuation runs on the same thread that causes the antecedent task to transition into its final state. If the antecedent is already complete when the continuation is created, the continuation will run on the thread that creates the continuation. If the antecedent's is disposed in a block ( in Visual Basic), a continuation with this option will run in that block. Only very short-running continuations should be executed synchronously. /// Because the task executes synchronously, there is no need to call a method such as to ensure that the calling thread waits for the task to complete. // Token: 0x040012EE RID: 4846 [Token(Token = "0x40012EE")] ExecuteSynchronously = 524288 } }