asyncAndThen<U, F> method

  1. @override
ResultAsync<U, F> asyncAndThen<U, F>(
  1. ResultAsync<U?, F?> f(
    1. T t
    )
)
override

Similar to map Except you must return a new Result.

This is useful for when you need to do a subsequent async computation using the inner T value, but that computation might fail. Must return a ResultAsync

@param f The function that returns a ResultAsync to apply to the current value

Implementation

@override
ResultAsync<U, F> asyncAndThen<U, F>(ResultAsync<U?, F?> Function(T t) f) =>
    errAsync(this.error as F);