Click or drag to resize
AsyncPump Class
Represents a pump that runs an asynchronous method and all its continuations on the current thread.
Inheritance Hierarchy
SystemObject
  Lawo.Threading.TasksAsyncPump

Namespace: Lawo.Threading.Tasks
Assembly: Lawo (in Lawo.dll) Version: 1.4.1707.27006
Syntax
C#
public static class AsyncPump

The AsyncPump type exposes the following members.

Methods
  NameDescription
Public methodStatic memberRun
Runs asyncMethod on the current thread.
Top
Remarks
Some asynchronous methods expect that all its continuations are executed on the same thread. If such code needs to be run in an environment where this is not guaranteed (Current is either null or is a SynchronizationContext object that schedules continuations on different threads as under ASP.NET) then this class can be used to force execution on a single thread.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
See Also