Table of Contents

Method Match

Namespace
SodaFlow.Async
Assembly
SodaFlow.Core.Async.dll

Match<T>(Func<T>, Func<Exception, T>)

Runs the handler for the end of this item, and returns its value.

public T Match<T>(Func<T> onSucceeded, Func<Exception, T> onFailed)

Parameters

onSucceeded Func<T>

Handles an operation that returned.

onFailed Func<Exception, T>

Handles a run with an error, with the exception from the operation.

Returns

T

The value that the handler returned.

Type Parameters

T

The type that each handler returns.