Table of Contents

Class TapExtensionsAsync

Namespace
Trellis
Assembly
Trellis.Core.dll

Provides asynchronous extension methods for executing side effects on successful Results without changing the Result.

public static class TapExtensionsAsync
Inheritance
TapExtensionsAsync
Inherited Members

Examples

var ct = cancellationToken;
var result = await GetUserDataAsync(userId)
    .TapAsync((email, name) => _logger.LogInformation("User: {Name} ({Email})", name, email))
    .TapAsync((email, name) => SendWelcomeEmailAsync(email, name, ct))
    .BindAsync((email, name) => CreateUserProfileAsync(email, name, ct));

Remarks

These methods handle various async scenarios with automatic tuple destructuring:

  • Async result ? sync action
  • Sync result ? async action
  • Async result ? async action

Both Task and ValueTask variants are provided for performance optimization scenarios. ValueTask is preferred for hot paths where the operation frequently completes synchronously.

Methods

TapAsync<TValue>(Task<Result<TValue>>, Action)

Asynchronously executes the given action if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Task<Result<TValue>> resultTask, Action action)

Parameters

resultTask Task<Result<TValue>>

The task containing the result to tap.

action Action

The action to execute if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(Task<Result<TValue>>, Action<TValue>)

Asynchronously executes the given action with the value if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Task<Result<TValue>> resultTask, Action<TValue> action)

Parameters

resultTask Task<Result<TValue>>

The task containing the result to tap.

action Action<TValue>

The action to execute with the value if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(Task<Result<TValue>>, Func<Task>)

Asynchronously executes the given async action if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Task<Result<TValue>> resultTask, Func<Task> func)

Parameters

resultTask Task<Result<TValue>>

The task containing the result to tap.

func Func<Task>

The async action to execute if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(Task<Result<TValue>>, Func<TValue, Task>)

Asynchronously executes the given async action with the value if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Task<Result<TValue>> resultTask, Func<TValue, Task> func)

Parameters

resultTask Task<Result<TValue>>

The task containing the result to tap.

func Func<TValue, Task>

The async action to execute with the value if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(ValueTask<Result<TValue>>, Action)

Asynchronously executes the given action if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this ValueTask<Result<TValue>> resultTask, Action action)

Parameters

resultTask ValueTask<Result<TValue>>

The ValueTask containing the result to tap.

action Action

The action to execute if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(ValueTask<Result<TValue>>, Action<TValue>)

Asynchronously executes the given action with the value if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this ValueTask<Result<TValue>> resultTask, Action<TValue> action)

Parameters

resultTask ValueTask<Result<TValue>>

The ValueTask containing the result to tap.

action Action<TValue>

The action to execute with the value if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(ValueTask<Result<TValue>>, Func<ValueTask>)

Asynchronously executes the given async action if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this ValueTask<Result<TValue>> resultTask, Func<ValueTask> valueTask)

Parameters

resultTask ValueTask<Result<TValue>>

The ValueTask containing the result to tap.

valueTask Func<ValueTask>

The async action to execute if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(ValueTask<Result<TValue>>, Func<TValue, ValueTask>)

Asynchronously executes the given async action with the value if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this ValueTask<Result<TValue>> resultTask, Func<TValue, ValueTask> valueTask)

Parameters

resultTask ValueTask<Result<TValue>>

The ValueTask containing the result to tap.

valueTask Func<TValue, ValueTask>

The async action to execute with the value if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(Result<TValue>, Func<Task>)

Asynchronously executes the given async action if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Result<TValue> result, Func<Task> func)

Parameters

result Result<TValue>

The result to tap.

func Func<Task>

The async action to execute if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

Remarks

OverloadResolutionPriorityAttribute resolves the historical CS0121 ambiguity against the sibling ValueTask-delegate overload on the same sync Result<TValue> receiver for inline async lambdas.

TapAsync<TValue>(Result<TValue>, Func<ValueTask>)

Asynchronously executes the given async action if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this Result<TValue> result, Func<ValueTask> func)

Parameters

result Result<TValue>

The result to tap.

func Func<ValueTask>

The async action to execute if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<TValue>(Result<TValue>, Func<TValue, Task>)

Asynchronously executes the given async action with the value if the result is a success. Returns the original result unchanged.

public static Task<Result<TValue>> TapAsync<TValue>(this Result<TValue> result, Func<TValue, Task> func)

Parameters

result Result<TValue>

The result to tap.

func Func<TValue, Task>

The async action to execute with the value if the result is successful.

Returns

Task<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

Remarks

OverloadResolutionPriorityAttribute resolves the historical CS0121 ambiguity against the sibling ValueTask-delegate overload on the same sync Result<TValue> receiver for inline async lambdas.

TapAsync<TValue>(Result<TValue>, Func<TValue, ValueTask>)

Asynchronously executes the given async action with the value if the result is a success. Returns the original result unchanged.

public static ValueTask<Result<TValue>> TapAsync<TValue>(this Result<TValue> result, Func<TValue, ValueTask> func)

Parameters

result Result<TValue>

The result to tap.

func Func<TValue, ValueTask>

The async action to execute with the value if the result is successful.

Returns

ValueTask<Result<TValue>>

The original result unchanged.

Type Parameters

TValue

Type of the result value.

TapAsync<T1, T2>(Task<Result<(T1, T2)>>, Action<T1, T2>)

Executes a synchronous side effect action on an asynchronous 2-element tuple result.

public static Task<Result<(T1, T2)>> TapAsync<T1, T2>(this Task<Result<(T1, T2)>> resultTask, Action<T1, T2> action)

Parameters

resultTask Task<Result<(T1, T2)>>

The task representing the result containing a 2-element tuple.

action Action<T1, T2>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2>(Task<Result<(T1, T2)>>, Func<T1, T2, Task>)

Executes an asynchronous side effect action on an asynchronous 2-element tuple result.

public static Task<Result<(T1, T2)>> TapAsync<T1, T2>(this Task<Result<(T1, T2)>> resultTask, Func<T1, T2, Task> func)

Parameters

resultTask Task<Result<(T1, T2)>>

The task representing the result containing a 2-element tuple.

func Func<T1, T2, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2>(ValueTask<Result<(T1, T2)>>, Action<T1, T2>)

Executes a synchronous side effect action on an asynchronous 2-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2)>> TapAsync<T1, T2>(this ValueTask<Result<(T1, T2)>> resultTask, Action<T1, T2> action)

Parameters

resultTask ValueTask<Result<(T1, T2)>>

The ValueTask representing the result containing a 2-element tuple.

action Action<T1, T2>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2>(ValueTask<Result<(T1, T2)>>, Func<T1, T2, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 2-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2)>> TapAsync<T1, T2>(this ValueTask<Result<(T1, T2)>> resultTask, Func<T1, T2, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2)>>

The ValueTask representing the result containing a 2-element tuple.

func Func<T1, T2, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2>(Result<(T1, T2)>, Func<T1, T2, Task>)

Executes an asynchronous side effect action on a synchronous 2-element tuple result.

public static Task<Result<(T1, T2)>> TapAsync<T1, T2>(this Result<(T1, T2)> result, Func<T1, T2, Task> func)

Parameters

result Result<(T1, T2)>

The result containing a 2-element tuple.

func Func<T1, T2, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2>(Result<(T1, T2)>, Func<T1, T2, ValueTask>)

Executes an asynchronous side effect action on a synchronous 2-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2)>> TapAsync<T1, T2>(this Result<(T1, T2)> result, Func<T1, T2, ValueTask> func)

Parameters

result Result<(T1, T2)>

The result containing a 2-element tuple.

func Func<T1, T2, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

TapAsync<T1, T2, T3>(Task<Result<(T1, T2, T3)>>, Action<T1, T2, T3>)

Executes a synchronous side effect action on an asynchronous 3-element tuple result.

public static Task<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this Task<Result<(T1, T2, T3)>> resultTask, Action<T1, T2, T3> action)

Parameters

resultTask Task<Result<(T1, T2, T3)>>

The task representing the result containing a 3-element tuple.

action Action<T1, T2, T3>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3>(Task<Result<(T1, T2, T3)>>, Func<T1, T2, T3, Task>)

Executes an asynchronous side effect action on an asynchronous 3-element tuple result.

public static Task<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this Task<Result<(T1, T2, T3)>> resultTask, Func<T1, T2, T3, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3)>>

The task representing the result containing a 3-element tuple.

func Func<T1, T2, T3, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3>(ValueTask<Result<(T1, T2, T3)>>, Action<T1, T2, T3>)

Executes a synchronous side effect action on an asynchronous 3-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this ValueTask<Result<(T1, T2, T3)>> resultTask, Action<T1, T2, T3> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3)>>

The ValueTask representing the result containing a 3-element tuple.

action Action<T1, T2, T3>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3>(ValueTask<Result<(T1, T2, T3)>>, Func<T1, T2, T3, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 3-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this ValueTask<Result<(T1, T2, T3)>> resultTask, Func<T1, T2, T3, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3)>>

The ValueTask representing the result containing a 3-element tuple.

func Func<T1, T2, T3, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3>(Result<(T1, T2, T3)>, Func<T1, T2, T3, Task>)

Executes an asynchronous side effect action on a synchronous 3-element tuple result.

public static Task<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this Result<(T1, T2, T3)> result, Func<T1, T2, T3, Task> func)

Parameters

result Result<(T1, T2, T3)>

The result containing a 3-element tuple.

func Func<T1, T2, T3, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3>(Result<(T1, T2, T3)>, Func<T1, T2, T3, ValueTask>)

Executes an asynchronous side effect action on a synchronous 3-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3)>> TapAsync<T1, T2, T3>(this Result<(T1, T2, T3)> result, Func<T1, T2, T3, ValueTask> func)

Parameters

result Result<(T1, T2, T3)>

The result containing a 3-element tuple.

func Func<T1, T2, T3, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

TapAsync<T1, T2, T3, T4>(Task<Result<(T1, T2, T3, T4)>>, Action<T1, T2, T3, T4>)

Executes a synchronous side effect action on an asynchronous 4-element tuple result.

public static Task<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this Task<Result<(T1, T2, T3, T4)>> resultTask, Action<T1, T2, T3, T4> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4)>>

The task representing the result containing a 4-element tuple.

action Action<T1, T2, T3, T4>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4>(Task<Result<(T1, T2, T3, T4)>>, Func<T1, T2, T3, T4, Task>)

Executes an asynchronous side effect action on an asynchronous 4-element tuple result.

public static Task<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this Task<Result<(T1, T2, T3, T4)>> resultTask, Func<T1, T2, T3, T4, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4)>>

The task representing the result containing a 4-element tuple.

func Func<T1, T2, T3, T4, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4>(ValueTask<Result<(T1, T2, T3, T4)>>, Action<T1, T2, T3, T4>)

Executes a synchronous side effect action on an asynchronous 4-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this ValueTask<Result<(T1, T2, T3, T4)>> resultTask, Action<T1, T2, T3, T4> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4)>>

The ValueTask representing the result containing a 4-element tuple.

action Action<T1, T2, T3, T4>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4>(ValueTask<Result<(T1, T2, T3, T4)>>, Func<T1, T2, T3, T4, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 4-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this ValueTask<Result<(T1, T2, T3, T4)>> resultTask, Func<T1, T2, T3, T4, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4)>>

The ValueTask representing the result containing a 4-element tuple.

func Func<T1, T2, T3, T4, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4>(Result<(T1, T2, T3, T4)>, Func<T1, T2, T3, T4, Task>)

Executes an asynchronous side effect action on a synchronous 4-element tuple result.

public static Task<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this Result<(T1, T2, T3, T4)> result, Func<T1, T2, T3, T4, Task> func)

Parameters

result Result<(T1, T2, T3, T4)>

The result containing a 4-element tuple.

func Func<T1, T2, T3, T4, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4>(Result<(T1, T2, T3, T4)>, Func<T1, T2, T3, T4, ValueTask>)

Executes an asynchronous side effect action on a synchronous 4-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4)>> TapAsync<T1, T2, T3, T4>(this Result<(T1, T2, T3, T4)> result, Func<T1, T2, T3, T4, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4)>

The result containing a 4-element tuple.

func Func<T1, T2, T3, T4, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(Task<Result<(T1, T2, T3, T4, T5)>>, Action<T1, T2, T3, T4, T5>)

Executes a synchronous side effect action on an asynchronous 5-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this Task<Result<(T1, T2, T3, T4, T5)>> resultTask, Action<T1, T2, T3, T4, T5> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5)>>

The task representing the result containing a 5-element tuple.

action Action<T1, T2, T3, T4, T5>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(Task<Result<(T1, T2, T3, T4, T5)>>, Func<T1, T2, T3, T4, T5, Task>)

Executes an asynchronous side effect action on an asynchronous 5-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this Task<Result<(T1, T2, T3, T4, T5)>> resultTask, Func<T1, T2, T3, T4, T5, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5)>>

The task representing the result containing a 5-element tuple.

func Func<T1, T2, T3, T4, T5, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(ValueTask<Result<(T1, T2, T3, T4, T5)>>, Action<T1, T2, T3, T4, T5>)

Executes a synchronous side effect action on an asynchronous 5-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this ValueTask<Result<(T1, T2, T3, T4, T5)>> resultTask, Action<T1, T2, T3, T4, T5> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5)>>

The ValueTask representing the result containing a 5-element tuple.

action Action<T1, T2, T3, T4, T5>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(ValueTask<Result<(T1, T2, T3, T4, T5)>>, Func<T1, T2, T3, T4, T5, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 5-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this ValueTask<Result<(T1, T2, T3, T4, T5)>> resultTask, Func<T1, T2, T3, T4, T5, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5)>>

The ValueTask representing the result containing a 5-element tuple.

func Func<T1, T2, T3, T4, T5, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(Result<(T1, T2, T3, T4, T5)>, Func<T1, T2, T3, T4, T5, Task>)

Executes an asynchronous side effect action on a synchronous 5-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this Result<(T1, T2, T3, T4, T5)> result, Func<T1, T2, T3, T4, T5, Task> func)

Parameters

result Result<(T1, T2, T3, T4, T5)>

The result containing a 5-element tuple.

func Func<T1, T2, T3, T4, T5, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5>(Result<(T1, T2, T3, T4, T5)>, Func<T1, T2, T3, T4, T5, ValueTask>)

Executes an asynchronous side effect action on a synchronous 5-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5)>> TapAsync<T1, T2, T3, T4, T5>(this Result<(T1, T2, T3, T4, T5)> result, Func<T1, T2, T3, T4, T5, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4, T5)>

The result containing a 5-element tuple.

func Func<T1, T2, T3, T4, T5, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(Task<Result<(T1, T2, T3, T4, T5, T6)>>, Action<T1, T2, T3, T4, T5, T6>)

Executes a synchronous side effect action on an asynchronous 6-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this Task<Result<(T1, T2, T3, T4, T5, T6)>> resultTask, Action<T1, T2, T3, T4, T5, T6> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6)>>

The task representing the result containing a 6-element tuple.

action Action<T1, T2, T3, T4, T5, T6>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(Task<Result<(T1, T2, T3, T4, T5, T6)>>, Func<T1, T2, T3, T4, T5, T6, Task>)

Executes an asynchronous side effect action on an asynchronous 6-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this Task<Result<(T1, T2, T3, T4, T5, T6)>> resultTask, Func<T1, T2, T3, T4, T5, T6, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6)>>

The task representing the result containing a 6-element tuple.

func Func<T1, T2, T3, T4, T5, T6, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>, Action<T1, T2, T3, T4, T5, T6>)

Executes a synchronous side effect action on an asynchronous 6-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6)>> resultTask, Action<T1, T2, T3, T4, T5, T6> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>

The ValueTask representing the result containing a 6-element tuple.

action Action<T1, T2, T3, T4, T5, T6>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>, Func<T1, T2, T3, T4, T5, T6, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 6-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6)>> resultTask, Func<T1, T2, T3, T4, T5, T6, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>

The ValueTask representing the result containing a 6-element tuple.

func Func<T1, T2, T3, T4, T5, T6, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(Result<(T1, T2, T3, T4, T5, T6)>, Func<T1, T2, T3, T4, T5, T6, Task>)

Executes an asynchronous side effect action on a synchronous 6-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this Result<(T1, T2, T3, T4, T5, T6)> result, Func<T1, T2, T3, T4, T5, T6, Task> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6)>

The result containing a 6-element tuple.

func Func<T1, T2, T3, T4, T5, T6, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6>(Result<(T1, T2, T3, T4, T5, T6)>, Func<T1, T2, T3, T4, T5, T6, ValueTask>)

Executes an asynchronous side effect action on a synchronous 6-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6)>> TapAsync<T1, T2, T3, T4, T5, T6>(this Result<(T1, T2, T3, T4, T5, T6)> result, Func<T1, T2, T3, T4, T5, T6, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6)>

The result containing a 6-element tuple.

func Func<T1, T2, T3, T4, T5, T6, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>, Action<T1, T2, T3, T4, T5, T6, T7>)

Executes a synchronous side effect action on an asynchronous 7-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>

The task representing the result containing a 7-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>, Func<T1, T2, T3, T4, T5, T6, T7, Task>)

Executes an asynchronous side effect action on an asynchronous 7-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>

The task representing the result containing a 7-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>, Action<T1, T2, T3, T4, T5, T6, T7>)

Executes a synchronous side effect action on an asynchronous 7-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>

The ValueTask representing the result containing a 7-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>, Func<T1, T2, T3, T4, T5, T6, T7, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 7-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>

The ValueTask representing the result containing a 7-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(Result<(T1, T2, T3, T4, T5, T6, T7)>, Func<T1, T2, T3, T4, T5, T6, T7, Task>)

Executes an asynchronous side effect action on a synchronous 7-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this Result<(T1, T2, T3, T4, T5, T6, T7)> result, Func<T1, T2, T3, T4, T5, T6, T7, Task> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7)>

The result containing a 7-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7>(Result<(T1, T2, T3, T4, T5, T6, T7)>, Func<T1, T2, T3, T4, T5, T6, T7, ValueTask>)

Executes an asynchronous side effect action on a synchronous 7-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>> TapAsync<T1, T2, T3, T4, T5, T6, T7>(this Result<(T1, T2, T3, T4, T5, T6, T7)> result, Func<T1, T2, T3, T4, T5, T6, T7, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7)>

The result containing a 7-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>, Action<T1, T2, T3, T4, T5, T6, T7, T8>)

Executes a synchronous side effect action on an asynchronous 8-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7, T8> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

The task representing the result containing a 8-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7, T8>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>, Func<T1, T2, T3, T4, T5, T6, T7, T8, Task>)

Executes an asynchronous side effect action on an asynchronous 8-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, T8, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

The task representing the result containing a 8-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>, Action<T1, T2, T3, T4, T5, T6, T7, T8>)

Executes a synchronous side effect action on an asynchronous 8-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7, T8> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

The ValueTask representing the result containing a 8-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7, T8>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>, Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 8-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

The ValueTask representing the result containing a 8-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(Result<(T1, T2, T3, T4, T5, T6, T7, T8)>, Func<T1, T2, T3, T4, T5, T6, T7, T8, Task>)

Executes an asynchronous side effect action on a synchronous 8-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this Result<(T1, T2, T3, T4, T5, T6, T7, T8)> result, Func<T1, T2, T3, T4, T5, T6, T7, T8, Task> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7, T8)>

The result containing a 8-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(Result<(T1, T2, T3, T4, T5, T6, T7, T8)>, Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask>)

Executes an asynchronous side effect action on a synchronous 8-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8>(this Result<(T1, T2, T3, T4, T5, T6, T7, T8)> result, Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7, T8)>

The result containing a 8-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>, Action<T1, T2, T3, T4, T5, T6, T7, T8, T9>)

Executes a synchronous side effect action on an asynchronous 9-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7, T8, T9> action)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

The task representing the result containing a 9-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7, T8, T9>

The side effect action to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task>)

Executes an asynchronous side effect action on an asynchronous 9-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task> func)

Parameters

resultTask Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

The task representing the result containing a 9-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>, Action<T1, T2, T3, T4, T5, T6, T7, T8, T9>)

Executes a synchronous side effect action on an asynchronous 9-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> resultTask, Action<T1, T2, T3, T4, T5, T6, T7, T8, T9> action)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

The ValueTask representing the result containing a 9-element tuple.

action Action<T1, T2, T3, T4, T5, T6, T7, T8, T9>

The side effect action to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask>)

Executes an asynchronous side effect action on an asynchronous 9-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> resultTask, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask> func)

Parameters

resultTask ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

The ValueTask representing the result containing a 9-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task>)

Executes an asynchronous side effect action on a synchronous 9-element tuple result.

public static Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)> result, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>

The result containing a 9-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, Task>

The async side effect function to execute on the tuple elements if successful.

Returns

Task<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A task that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.

TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask>)

Executes an asynchronous side effect action on a synchronous 9-element tuple result (ValueTask variant).

public static ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>> TapAsync<T1, T2, T3, T4, T5, T6, T7, T8, T9>(this Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)> result, Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask> func)

Parameters

result Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>

The result containing a 9-element tuple.

func Func<T1, T2, T3, T4, T5, T6, T7, T8, T9, ValueTask>

The async side effect function to execute on the tuple elements if successful.

Returns

ValueTask<Result<(T1, T2, T3, T4, T5, T6, T7, T8, T9)>>

A ValueTask that represents the asynchronous operation containing the original result unchanged.

Type Parameters

T1

The type of element 1 in the tuple.

T2

The type of element 2 in the tuple.

T3

The type of element 3 in the tuple.

T4

The type of element 4 in the tuple.

T5

The type of element 5 in the tuple.

T6

The type of element 6 in the tuple.

T7

The type of element 7 in the tuple.

T8

The type of element 8 in the tuple.

T9

The type of element 9 in the tuple.