The recording of the first ever ReactiveUI virtual conference is available on our YouTube Channel.

Notification<T>.Accept<TResult>(Func<T, TResult>, Func<Exception, TResult>, Func<TResult>)

Notification<T>.Accept<TResult> Method (Func<T, TResult>, Func<Exception, TResult>, Func<TResult>)

Invokes the delegate corresponding to the notification and returns the produced result.

Namespace:  System.Reactive
Assembly:  System.Reactive (in System.Reactive.dll)


Public MustOverride Function Accept(Of TResult) ( _
    onNext As Func(Of T, TResult), _
    onError As Func(Of Exception, TResult), _
    onCompleted As Func(Of TResult) _
) As TResult
Dim instance As Notification
Dim onNext As Func(Of T, TResult)
Dim onError As Func(Of Exception, TResult)
Dim onCompleted As Func(Of TResult)
Dim returnValue As TResult

returnValue = instance.Accept(onNext, _
    onError, onCompleted)
public abstract TResult Accept<TResult>(
    Func<T, TResult> onNext,
    Func<Exception, TResult> onError,
    Func<TResult> onCompleted
generic<typename TResult>
virtual TResult Accept(
    Func<T, TResult>^ onNext, 
    Func<Exception^, TResult>^ onError, 
    Func<TResult>^ onCompleted
) abstract
abstract Accept : 
        onNext:Func<'T, 'TResult> * 
        onError:Func<Exception, 'TResult> * 
        onCompleted:Func<'TResult> -> 'TResult 
JScript does not support generic types and methods.

Type Parameters

  • TResult
    The result argument type.


  • onNext
    Type: System.Func<T, TResult>
    The delegate to invoke for an OnNext notification.

  • onError
    Type: System.Func<Exception, TResult>
    The delegate to invoke for an OnError notification.

  • onCompleted
    Type: System.Func<TResult>
    The delegate to invoke for an OnCompleted notification.

Return Value

Type: TResult
The result produced by the observation..

See Also


Notification<T> Class

Accept Overload

System.Reactive Namespace