Skip to content

)} ,System.Reactive.Concurrency.IScheduler)}

Qbservable.ToObservable(IQbservableProvider, IEnumerable) method

Defined in

Type: Qbservable Namespace: System.Reactive.Linq Assembly: System.Reactive.dll

Applies to

netstandard2.0

Overloads

  • 1. public static IQbservable<TSource> ToObservable<TSource>(this IQbservableProvider provider, IEnumerable<TSource> source)
  • 2. public static IQbservable<TSource> ToObservable<TSource>(this IQbservableProvider provider, IEnumerable<TSource> source, IScheduler scheduler)

1. Overload

public static IQbservable<TSource> ToObservable<TSource>(this IQbservableProvider provider, IEnumerable<TSource> source)

Summary: Converts an enumerable sequence to an observable sequence.

Type parameters

NameDescription
TSourceThe type of the elements in the source sequence.

Parameters

NameTypeDescription
provider[IQbservableProvider](#Query provider used to construct the [IQbservable](# data source.
sourceIEnumerableEnumerable sequence to convert to an observable sequence.

Returns: IQbservable -- The observable sequence whose elements are pulled from the given enumerable sequence.

Exceptions

TypeCondition
System.ArgumentNullExceptionsource is null.

2. Overload

public static IQbservable<TSource> ToObservable<TSource>(this IQbservableProvider provider, IEnumerable<TSource> source, IScheduler scheduler)

Summary: Converts an enumerable sequence to an observable sequence, using the specified scheduler to run the enumeration loop.

Type parameters

NameDescription
TSourceThe type of the elements in the source sequence.

Parameters

NameTypeDescription
provider[IQbservableProvider](#Query provider used to construct the [IQbservable](# data source.
sourceIEnumerableEnumerable sequence to convert to an observable sequence.
scheduler[IScheduler](#Scheduler to run the enumeration of the input sequence on.

Returns: IQbservable -- The observable sequence whose elements are pulled from the given enumerable sequence.

Exceptions

TypeCondition
System.ArgumentNullExceptionsource or scheduler is null.