Click or drag to resize

CancellableOperationT Class

Class that can be cancelled. - The class holds a reference to the system threaded Task that will - process the cancellable logic. - Holds a cancellation token source linked to the token passed via the constructor.
Inheritance Hierarchy

Namespace:  MFiles.VAF.MultiserverMode
Assembly:  MFiles.VAF (in MFiles.VAF.dll) Version: 2.2.0.9
Syntax
C#
public abstract class CancellableOperation<T>
where T : class, IDeepCloneable

Type Parameters

T
Backing data object.

The CancellableOperationT type exposes the following members.

Constructors
Properties
  NameDescription
Public propertyData
Data value clone container.
Protected propertyLinkedTokenSource
Protected linked cancellation token source. - Used to request cancellation of the process.
Public propertyTask
The system task that processes this operation.
Public propertyToken
Linked cancellation token.
Top
Methods
  NameDescription
Public methodCancel
Requests cancellation of the operation.
Public methodCancelAfter
Requests cancellation of the operation.
Protected methodOnCancellationRequested
Cancellation requested event invocation.
Public methodResetCancellationToken
Resets the cancellation token source.
Public methodThrowIfCancellationRequested
If cancellation has been requested: - The CancellationRequest event is fired. - Then the cancellation exception is thrown.
Protected methodThrowIfNull
Asserts the passed object is not null.
Protected methodTriggerCancellationRequested
Triggers the cancellation requested event, for any registered listeners.
Top
Events
  NameDescription
Public eventCancellationRequested
Event fired on cancellation requested.
Top
See Also