Asynchronous programming patterns in .NET:
- Asynchronous Programming Model (BeginOperation/EndOperation)
- Event-based Asynchronous Pattern (invoke event with result from async job)
- Task-based Asynchronous Pattern (Task<>)
Ways of achieving asynchronous code in .NET
- async, await
Task
class API (Run
,WhenAll
,WhenAny
, etc.)ThreadPool.QueueUserWorkItem(ThreadProc);
Further read:
https://learn.microsoft.com/en-us/dotnet/standard/asynchronous-programming-patterns/