})} },System.Reactive.Concurrency.TaskObservationOptions)} },System.Reactive.Concurrency.IScheduler)} })} },System.Reactive.Concurrency.TaskObservationOptions)} },System.Reactive.Concurrency.IScheduler)} }})} }})} }},System.Reactive.Concurrency.TaskObservationOptions)} }},System.Reactive.Concurrency.TaskObservationOptions)} }},System.Reactive.Concurrency.IScheduler)} }},System.Reactive.Concurrency.IScheduler)}
Qbservable.FromAsync(IQbservableProvider, Expression>) method¶
Defined in
Type: Qbservable
Namespace: System.Reactive.Linq
Assembly: System.Reactive.dll
Applies to
netstandard2.0
Overloads¶
- 1.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync) - 2.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync, TaskObservationOptions options) - 3.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync, IScheduler scheduler) - 4.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync) - 5.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync, TaskObservationOptions options) - 6.
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync, IScheduler scheduler) - 7.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync) - 8.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync) - 9.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync, TaskObservationOptions options) - 10.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync, TaskObservationOptions options) - 11.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync, IScheduler scheduler) - 12.
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync, IScheduler scheduler)
1. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null. |
2. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync, TaskObservationOptions options)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
options | [TaskObservationOptions](# | Controls how the tasks's progress is observed. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null. |
3. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<Task>> actionAsync, IScheduler scheduler)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
scheduler | [IScheduler](# | Scheduler on which to notify observers. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null or scheduler is null. |
4. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started. The CancellationToken passed to the asynchronous action is tied to the observable sequence's subscription that triggered the action's invocation and can be used for best-effort cancellation.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null. |
5. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync, TaskObservationOptions options)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started. The CancellationToken passed to the asynchronous action is tied to the observable sequence's subscription that triggered the action's invocation and can be used for best-effort cancellation.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
options | [TaskObservationOptions](# | Controls how the tasks's progress is observed. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null. |
6. Overload¶
public static IQbservable<Unit> FromAsync(this IQbservableProvider provider, Expression<Func<CancellationToken, Task>> actionAsync, IScheduler scheduler)
Summary: Converts an asynchronous action into an observable sequence. Each subscription to the resulting sequence causes the action to be started. The CancellationToken passed to the asynchronous action is tied to the observable sequence's subscription that triggered the action's invocation and can be used for best-effort cancellation.
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
actionAsync | Expression | Asynchronous action to convert. |
scheduler | [IScheduler](# | Scheduler on which to notify observers. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | actionAsync is null or scheduler is null. |
7. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null. |
8. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started. The CancellationToken passed to the asynchronous function is tied to the observable sequence's subscription that triggered the function's invocation and can be used for best-effort cancellation.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null. |
9. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync, TaskObservationOptions options)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
options | [TaskObservationOptions](# | Controls how the tasks's progress is observed. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null. |
10. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync, TaskObservationOptions options)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started. The CancellationToken passed to the asynchronous function is tied to the observable sequence's subscription that triggered the function's invocation and can be used for best-effort cancellation.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
options | [TaskObservationOptions](# | Controls how the tasks's progress is observed. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null. |
11. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<Task<TResult>>> functionAsync, IScheduler scheduler)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
scheduler | [IScheduler](# | Scheduler on which to notify observers. |
Returns: IQbservable
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null or scheduler is null. |
12. Overload¶
public static IQbservable<TResult> FromAsync<TResult>(this IQbservableProvider provider, Expression<Func<CancellationToken, Task<TResult>>> functionAsync, IScheduler scheduler)
Summary: Converts an asynchronous function into an observable sequence. Each subscription to the resulting sequence causes the function to be started. The CancellationToken passed to the asynchronous function is tied to the observable sequence's subscription that triggered the function's invocation and can be used for best-effort cancellation.
Type parameters
| Name | Description |
|---|---|
TResult | The type of the result returned by the asynchronous function. |
Parameters
| Name | Type | Description |
|---|---|---|
provider | [IQbservableProvider](# | Query provider used to construct the [IQbservable](# data source. |
functionAsync | Expression | Asynchronous function to convert. |
scheduler | [IScheduler](# | Scheduler on which to notify observers. |
Returns: IQbservable
Remarks
When a subscription to the resulting sequence is disposed, the CancellationToken that was fed to the asynchronous function will be signaled.
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException | functionAsync is null or scheduler is null. |