<PackageReference Include="ReactiveUI.Primitives.Core" Version="10.0.0" />

ReactiveUI.Primitives.Advanced.Witness

public static class Witness
Factory methods for allocation-conscious observers in the ReactiveUI.Primitives vocabulary.
public static IObserver<T> Create<T>(Action<T> onNext)

Creates a witness from an onNext delegate and default terminal handlers.

public static IObserver<T> Create<T>(Action<T> onNext, Action<Exception> onError)

Creates a witness from value and error delegates.

public static IObserver<T> Create<T>(Action<T> onNext, Action onCompleted)

Creates a witness from value and completion delegates.

public static IObserver<T> Create<T>(Action<T> onNext, Action<Exception> onError, Action onCompleted)

Creates a witness from explicit value, error, and completion callbacks.

public static IObserver<T> Safe<T>(IObserver<T> observer)

Wraps a witness so it receives at most one terminal signal and no values after termination.

public static IObserver<T> Safe<T>(IObserver<T> observer, IDisposable cancel)

Wraps a witness so it receives at most one terminal signal and no values after termination.