Skip to content

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

Observer.NotifyOn(IObserver, IScheduler) method

Defined in

Type: Observer Namespace: System.Reactive Assembly: System.Reactive.dll

Applies to

netstandard2.0

Overloads

  • 1. public static IObserver<T> NotifyOn<T>(this IObserver<T> observer, IScheduler scheduler)
  • 2. public static IObserver<T> NotifyOn<T>(this IObserver<T> observer, SynchronizationContext context)

1. Overload

public static IObserver<T> NotifyOn<T>(this IObserver<T> observer, IScheduler scheduler)

Summary: Schedules the invocation of observer methods on the given scheduler.

Type parameters

NameDescription
TThe type of the elements received by the source observer.

Parameters

NameTypeDescription
observerIObserverThe observer to schedule messages for.
scheduler[IScheduler](#Scheduler to schedule observer messages on.

Returns: IObserver -- Observer whose messages are scheduled on the given scheduler.

Exceptions

TypeCondition
System.ArgumentNullExceptionobserver or scheduler is null.

2. Overload

public static IObserver<T> NotifyOn<T>(this IObserver<T> observer, SynchronizationContext context)

Summary: Schedules the invocation of observer methods on the given synchronization context.

Type parameters

NameDescription
TThe type of the elements received by the source observer.

Parameters

NameTypeDescription
observerIObserverThe observer to schedule messages for.
contextSynchronizationContextSynchronization context to schedule observer messages on.

Returns: IObserver -- Observer whose messages are scheduled on the given synchronization context.

Exceptions

TypeCondition
System.ArgumentNullExceptionobserver or context is null.