Concurrent class¶
Defined in
Namespace: ReactiveUI.Extensions.Async.Subjects
Assembly: ReactiveUI.Extensions.dll
Full name: ReactiveUI.Extensions.Async.Subjects.Concurrent
Modifiers: public static
Summary¶
Provides helper methods for forwarding asynchronous observer notifications concurrently to multiple observers.
Applies to
net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-browserwasm1.0, net9.0-desktop1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, net462, net481
Remarks¶
The methods in this class are intended for scenarios where multiple asynchronous observers need to be notified in parallel. All observer notifications are dispatched concurrently, and the returned ValueTask completes when all observer operations have finished. If the observers collection is empty, the methods complete immediately. Exceptions thrown by individual observers are aggregated into a single exception, consistent with Task.WhenAll behavior.
Methods¶
| Name | Summary |
|---|---|
| static ForwardOnNextConcurrently | Forwards the specified value to all observers concurrently by invoking their OnNextAsync methods. |
| static ForwardOnErrorResumeConcurrently | Forwards an error notification to all specified asynchronous observers concurrently, allowing each observer to handle the error and resume as appropriate. |
| static ForwardOnCompletedConcurrently | Invokes the OnCompletedAsync method on each observer in the collection concurrently, forwarding the specified result to all observers. |