Skip to content

ObservableAsync class

Defined in

Namespace: ReactiveUI.Extensions.Async Assembly: ReactiveUI.Extensions.dll Full name: ReactiveUI.Extensions.Async.ObservableAsync Modifiers: public static

Summary

View source

        Provides Zip extension methods for asynchronous observable sequences.
        

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

Zip combines elements from two observable sequences pair-wise. The nth element from each source is paired together. The resulting sequence completes when either source completes.

Methods

NameSummary
static CreateCreates a new asynchronous observable sequence using the specified subscription function.
static CreateAsBackgroundJobCreates a new observable sequence that runs the specified asynchronous job as a background task.
static DeferCreates a new observable sequence for each subscription by invoking the specified asynchronous factory function.
static EmptyCreates an observable sequence that completes immediately without emitting any items.
static FromAsyncCreates an asynchronous observable sequence that emits a single value produced by the specified factory function.
static IntervalCreates an asynchronous observable sequence that emits a long integer value at each specified time interval.
static NeverCreates an observable sequence that never produces any values and never completes.
static RangeCreates an observable sequence that emits a range of consecutive integer values, starting from the specified value.
static ReturnCreates an observable sequence that emits a single value and then completes.
static ThrowCreates an observable sequence that terminates immediately with the specified exception.
static TimerCreates an observable sequence that produces a single value (0) after the specified delay, then completes.
static ToObservableAsyncConverts a task representing a single asynchronous value into an observable sequence that emits the result when the task completes.
static AggregateAsyncApplies an asynchronous accumulator function over the observable sequence, returning the final accumulated value when the sequence completes.
static AnyAsyncAsynchronously determines whether any element in the sequence satisfies the specified predicate.
static AllAsyncAsynchronously determines whether all elements in the sequence satisfy the specified predicate.
static CastProjects each element of the observable sequence to the specified result type by performing a runtime cast.
static CatchCreates a new observable sequence that continues with a handler-provided sequence when an exception occurs in the source sequence.
static CatchAndIgnoreErrorResumeContinues the observable sequence with an alternative sequence provided by the specified handler when an error occurs, and ignores the error after invoking the handler.
static CombineLatestCombines the latest values from ten asynchronous observable sources into a single sequence, projecting them through selector whenever any source emits.
static ConcatConcatenates a sequence of asynchronous observable sequences into a single observable sequence, subscribing to each inner sequence in order only after the previous one completes.
static ContainsAsyncAsynchronously determines whether the sequence contains a specified value using the given equality comparer.
static CountAsyncAsynchronously counts the number of elements that satisfy a specified condition.
static DelayTime-shifts the observable sequence by the specified time span. Each element notification is delayed by the specified duration.
static DistinctReturns a sequence that contains only distinct elements from the source sequence, using the default equality comparer for the element type.
static DistinctByReturns a sequence that contains distinct elements from the source sequence according to a specified key selector function.
static DistinctUntilChangedReturns an observable sequence that emits only distinct consecutive elements, suppressing duplicates that are equal to the previous element.
static DistinctUntilChangedByReturns an observable sequence that emits elements from the source sequence, suppressing consecutive duplicates as determined by a key selector function.
static DoInvokes the specified asynchronous actions for each element, error, or completion notification in the observable sequence without modifying the sequence.
static FirstAsyncAsynchronously returns the first element in the sequence that satisfies the specified predicate.
static FirstOrDefaultAsyncAsynchronously returns the first element that matches the specified predicate, or a default value if no such element is found.
static ForEachAsyncAsynchronously invokes the specified action for each element in the sequence as elements are received.
static GroupByGroups the elements of an asynchronous observable sequence according to a specified key selector function.
static LastAsyncAsynchronously returns the last element in the sequence that satisfies the specified predicate.
static LastOrDefaultAsyncAsynchronously returns the last element in the sequence that satisfies the specified predicate, or a default value if no such element is found.
static LongCountAsyncAsynchronously returns the number of elements in the sequence that satisfy an optional predicate.
static MergeMerges multiple asynchronous observable sequences into a single observable sequence that emits items from all inner sequences as they arrive.
static MulticastCreates a connectable observable sequence that shares a single subscription to the underlying sequence using the specified subject.
static PublishReturns a connectable observable sequence that shares a single subscription to the underlying asynchronous observable. Observers will receive all notifications published after they...
static StatelessPublishCreates a connectable observable sequence that shares a single subscription to the underlying source and does not retain any state between subscriptions.
static ReplayLatestPublishCreates a connectable observable sequence that replays only the most recent item to new subscribers.
static StatelessReplayLatestPublishCreates a connectable observable sequence that replays only the latest item to new subscribers and publishes items to all current subscribers.
static ObserveOnWraps the source observable so that observer callbacks are invoked on the specified async context.
static OfTypeProjects each element of the observable sequence to the specified reference type and filters out elements that are not of that type.
static OnDisposeRegisters a callback to be invoked asynchronously when the observable sequence is disposed.
static OnErrorResumeAsFailureCreates a new observable sequence that converts any error encountered in the source sequence into a failure result, allowing the sequence to complete without propagating exceptions.
static AsSignal
static CatchIgnore
static CatchAndReturn
static DoOnSubscribe
static DropIfBusy
static LatestOrDefault
static LogErrors
static WaitUntil
static ObserveOnSafe
static ObserveOnIf
static Pairwise
static Partition
static ReplayLastOnSubscribe
static ThrottleDistinct
static ScanWithInitial
static DebounceUntil
static GetMinReturns the minimum of the latest values from the supplied source sequences.
static GetMaxReturns the maximum of the latest values from the supplied source sequences.
static CombineLatestValuesAreAllFalseEmits true when the latest value from every source sequence is false.
static CombineLatestValuesAreAllTrueEmits true when the latest value from every source sequence is true.
static ForEachFlattens each enumerable element emitted by the source into individual values.
static NotNegates each boolean value emitted by the source sequence.
static SkipWhileNullSkips null values until the first non-null value appears.
static StartCreates an observable sequence that executes the supplied action and emits [Default](#
static WhereFalseFilters the source sequence to false values.
static WhereIsNotNullFilters the source sequence to non-null values and narrows the result type accordingly.
static WhereTrueFilters the source sequence to true values.
static PrependReturns a new observable sequence that begins with the specified value, followed by the elements of the current sequence.
static RefCountReturns an observable sequence that connects to the underlying connectable observable when the first observer subscribes, and disconnects when the last observer unsubscribes.
static RetryRepeats the source observable sequence indefinitely until it completes successfully, re-subscribing on each error.
static ScanApplies an accumulator function over the observable sequence and returns each intermediate result using the specified asynchronous accumulator.
static SelectProjects each element of the observable sequence into a new form using the specified asynchronous selector function.
static SelectManyProjects each element of the observable sequence to an asynchronous observable sequence and merges the resulting sequences into one observable sequence.
static SingleAsyncAsynchronously returns the single element of a sequence that satisfies a specified condition, or throws an exception if more than one such element exists.
static SingleOrDefaultAsyncAsynchronously returns the only element of a sequence that satisfies a specified condition, or a default value if no such element exists; this operation throws if more than one matching...
static SkipReturns a new observable sequence that skips the specified number of elements from the start of the source sequence.
static SkipWhileBypasses elements in the observable sequence as long as the specified asynchronous condition is true, then emits all remaining elements.
static StartWithPrepends the specified value to the beginning of the observable sequence.
static SubscribeAsyncSubscribes to the asynchronous data source and invokes the specified callbacks for each item, error, or completion notification.
static SwitchTransforms an observable sequence of observable sequences into a single observable sequence that emits values from the most recent inner observable sequence.
static TakeReturns a new observable sequence that emits only the first specified number of elements from the source sequence.
static TakeUntil
static TakeWhileReturns elements from the observable sequence as long as the specified asynchronous condition is true, then completes.
static ThrottleIgnores elements from the source sequence that are followed by another element within the specified time span. Only the last element in each burst is forwarded.
static TimeoutApplies a dueTime policy to the observable sequence. If the next element is not received within the specified time span, the sequence completes with a...
static ToAsyncEnumerableConverts the specified asynchronous observable sequence to an asynchronous enumerable sequence, enabling consumption using asynchronous iteration.
static ToDictionaryAsyncAsynchronously creates a dictionary from the elements of the sequence, using the specified key selector function.
static ToListAsyncAsynchronously collects all elements from the source sequence into a list.
static UsingCreates an observable sequence that manages the lifetime of an asynchronous resource, ensuring the resource is disposed when the sequence terminates.
static WaitCompletionAsyncAsynchronously waits for the observable sequence to complete without retrieving any values.
static WhereCreates a new observable sequence that contains only the elements from the source sequence that satisfy the specified asynchronous predicate.
static WrapWraps the specified asynchronous observer in a decorator that ensures consistent behavior and interface compliance.
static YieldReturns an observable sequence that yields control to the current thread's scheduler before emitting items from the source sequence.
static ZipCombines two observable sequences element-by-element using the specified result selector.
Inherited members

Extension blocks

extension(IObservableAsync source)

  • AsSignal
  • CatchIgnore
  • CatchIgnore
  • CatchAndReturn
  • CatchAndReturn
  • DoOnSubscribe
  • DoOnSubscribe
  • DropIfBusy
  • LatestOrDefault
  • LogErrors
  • WaitUntil
  • ObserveOnSafe
  • ObserveOnSafe
  • ObserveOnSafe
  • ObserveOnSafe
  • ObserveOnIf
  • ObserveOnIf
  • ObserveOnIf
  • ObserveOnIf
  • Pairwise
  • Partition
  • ReplayLastOnSubscribe
  • ThrottleDistinct
  • ThrottleDistinct
  • ScanWithInitial
  • ScanWithInitial
  • DebounceUntil
  • DebounceUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil
  • TakeUntil