Click or drag to resize

TaskCancelController Class

Controls the background execution of a thread or a task.
Inheritance Hierarchy
SystemObject
  Altaxo.Gui.CommonTaskCancelController

Namespace: Altaxo.Gui.Common
Assembly: AltaxoBase (in AltaxoBase.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public class TaskCancelController : INotifyPropertyChanged, 
	IDisposable

The TaskCancelController type exposes the following members.

Constructors
 NameDescription
Public methodTaskCancelControllerInitializes a new instance of the TaskCancelController class
Public methodTaskCancelController(Task, IProgressMonitor, Int32)Initializes a new instance of the TaskCancelController class
Public methodTaskCancelController(Thread, IProgressMonitor, Int32)Initializes a new instance of the TaskCancelController class
Top
Properties
Methods
 NameDescription
Protected methodCreateTimer 
Public methodDisposeReleases all resources used by the TaskCancelController
Protected methodEhAbandon 
Protected methodEhAbort 
Protected methodEhInterrupt 
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodOnPropertyChanged 
Public methodStartExecution 
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Events
 NameDescription
Public eventPropertyChanged 
Top
Fields
 NameDescription
Protected field_delayMilliseconds 
Protected field_timer 
Top
Remarks
There is a property IsWindowVisible, which is set to true after a given amount of time, and then set to false when the window should close. There is another property IsExecutionInProgress that indicates if currently a task/thread is executed. The order a task or thread is stopped is this: 1. Signal the CancellationTokenSoft 2. Signal the CancellationTokenHard 3. Interrupt the thread (only works for threads) 4. Abort the thread (only works for threads)
See Also